-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Is Json.NET Supporting .NET 7 AOT? #2732
Comments
Unlikely. It wasn’t designed for AOT and adding something like a generator would be a huge amount of work. |
@JamesNK So what now? Will there be a compatible version or should I look for a different Json Package? I'm not able to publish my app on iOS unless I have it use the interpreter. |
use |
why?? |
Would just falling back to reflection in the AOT scenario be a more feasible step forward? My guess is that reflection is plenty fast enough for most users. |
AOT includes trimming, which strips away a lot of reflection metadata. Source generation is basically a requirement for the AOT scenario. |
Stephen Toub has mentioned in https://devblogs.microsoft.com/dotnet/performance_improvements_in_net_7/comment-page-3/#native-aot
that if you publish a .NET 7 application with AOT support no JIT compiler exists. Is Json.NET able to work around that like System.Text.Json which has since .NET 6.0 compile time source generator support? I would love to continue to use Json.NET because it I still want to target .NET 4.8.
The text was updated successfully, but these errors were encountered: