You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
10.x: Native AOT published with the .NET 11 SDK traps (SIGTRAP) on the first value set ToString (dotnet/runtime#136073) #299
A Native AOT publish of a consumer with the .NET 11 SDK (RC2 11.0.100-rc.2.26504.105, ILCompiler 11.0.0-rc.2, osx-arm64) dies with SIGTRAP (exit 133, nothing on stderr) on the first ToString() of any value set. ILCompiler compiles the instantiating stub for the default IFormattable.ToString of IValueSetFactory<TSet, T> to a trap (dotnet/runtime#136073), and every set type's ToString() runs through that default.
#291 measured this on the 11 line and against the unchanged 10.0.0 package: a net11.0 program referencing CodoMetis.ValueRanges 10.0.0 traps the same way. So the released 10.x line meets it through every consumer who publishes Native AOT with the .NET 11 SDK. That is a realistic LTS configuration: 10.x is supported to 2028-11, and 11.x carries a breaking surface change (#275), so applications that move to .NET 11 and keep the 10.x packages are expected.
Not reproduced in this repository's CI, which has no .NET 11 SDK; the 10.0.0 package passes test/consumer-smoke-test.sh's NativeAOT leg under the .NET 10 SDK. Loud, not silent.
Change
Port the #291 workaround from PR #292 to release/10.x: every set type (the twelve core families, their wrapper arities, the five NodaTime families) implements IFormattable.ToString explicitly and its ToString() calls SetFormat.Format directly, so the interface's default is never the implementation a compiled consumer runs. The interface keeps its default. Public surface unchanged (explicit interface implementations), so the ApiCompat baseline against 10.0.0 holds.
PR #292 is a single commit holding the whole retarget, so this is a hand-extracted commit that names the PR, not a cherry-pick -x.
Done when
A net11.0 NativeAOT consumer of the 10.1.0 packages prints every set type, measured with the .NET 11 RC2 (or newer) SDK, and test/consumer-smoke-test.sh says how to run its AOT leg with a .NET 11 SDK (a global.json beside the consumer), so the check can be repeated by hand until #297 decides whether 10.x CI gets a .NET 11 SDK leg.
Port is in #309 (against release/10.x). Measured with SDK 11.0.100-rc.2.26504.105 on osx-arm64 through SMOKE_AOT_SDK=… test/consumer-smoke-test.sh: the base without the change (48b9651) traps with exit 133 after aot-float64set; with the change the native binary runs to the end and the new aot-set-tostring-every-family case prints all seventeen families. The smoke test's header now says how to run its AOT leg with a .NET 11 SDK. Close by hand once #309 merges, since Closes acts only on main.
Fixed on release/10.x by PR #309 (merge commit 4233dea, 2026-10-19). Closed by hand: Closes acts only on main, where the workaround arrived with PR #292 (#291).
Activity
fix: implement IFormattable on every value set so Native AOT with the…
CaffeinatedCoder commentedon Oct 19, 2026
Port is in #309 (against
release/10.x). Measured with SDK 11.0.100-rc.2.26504.105 on osx-arm64 throughSMOKE_AOT_SDK=… test/consumer-smoke-test.sh: the base without the change (48b9651) traps with exit 133 afteraot-float64set; with the change the native binary runs to the end and the newaot-set-tostring-every-familycase prints all seventeen families. The smoke test's header now says how to run its AOT leg with a .NET 11 SDK. Close by hand once #309 merges, sinceClosesacts only onmain.Merge release/10.x into fix/299-aot-set-tostring-net11-sdk
CaffeinatedCoder commentedon Oct 19, 2026
Fixed on
release/10.xby PR #309 (merge commit 4233dea, 2026-10-19). Closed by hand:Closesacts only onmain, where the workaround arrived with PR #292 (#291).