Skip to content

Fix NativeAOT startup with embedded trimming descriptor - #40

Merged
JordanMarr merged 1 commit into
JordanMarr:mainfrom
slyshykO:fix-native-aot
Nov 18, 2026
Merged

JordanMarr merged 1 commit into
JordanMarr:mainfrom
slyshykO:fix-native-aot

Conversation

@slyshykO

Copy link
Copy Markdown
Contributor

Preserve ListModule.OfArray and verify a packed .NET 10 NativeAOT consumer in CI. Add net10.0 to TestConsole alongside net6.0.

Preserve ListModule.OfArray and verify a packed .NET 10 NativeAOT consumer in CI. Add net10.0 to TestConsole alongside net6.0.
@JordanMarr
JordanMarr merged commit 90b7e8a into JordanMarr:main Nov 18, 2026
1 check passed
JordanMarr added a commit that referenced this pull request Nov 18, 2026
Keep the embedded trimming descriptor, but replace the NativeAOT consumer
project and CI step with a unit test that verifies the descriptor is
embedded and its entries resolve. Revert TestConsole to net6.0 only.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@JordanMarr

Copy link
Copy Markdown
Owner

Thanks @slyshykO, and sorry for the slow reply! The startup crash was a real bug from the list-input changes in #38, and the embedded descriptor is a nice fix because app authors don't have to do anything.

I merged it, then followed up with a tidy commit (5c67932) that keeps the descriptor but removes the NativeAOT test project, the CI step and the net10.0 target in TestConsole. I don't use AOT myself yet, so I can't really maintain it as a supported target. Instead, there's now a unit test that checks the descriptor is embedded and that its entries still resolve, plus a comment by the OfArray lookup pointing to the descriptor.

The fix is in v2.3.1, which is now on NuGet. If you run into other AOT problems, especially with list inputs of value types like int list, please open an issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants