-
Notifications
You must be signed in to change notification settings - Fork 545
[Xamarin.Android.Build.Tasks] emit XA1040 for experimental runtimes #9834
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
Conversation
MonoVM is currently the default (and supported!) runtime for .NET for Android. Emit `XA1040` when the user opts into using the experimental runtimes, such as: * `$(UseMonoRuntime)=false` CoreCLR * `$(PublishAot)=true` NativeAOT If desired, you can opt out of the warning completely with `$(AndroidAllowExperimentalRuntime)=true`, or use existing MSBuild mechanisms to suppress it.
Based kind of around the messaging EF has here: https://learn.microsoft.com/en-us/ef/core/performance/nativeaot-and-precompiled-queries
We could also require the user to set this like the runtime does for experimental features:
|
Right now we have the same Are you saying to just use the same property to opt out of the warning? |
Yeah, it feels like the accepted ".NET way" of doing this would be to always throw this message as an error unless the user sets I realize technically this is a bit different because it's not an API/assembly decorated with The .NET documented standard is Granted, this is bikeshedding over naming, so treat this just as a suggestion. 😉 |
I like the |
…9834) MonoVM is currently the default (and supported!) runtime for .NET for Android. Emit warning XA1040 when the user opts into using the experimental runtimes, such as: * CoreCLR, via `$(UseMonoRuntime)=false` * NativeAOT, via `$(PublishAot)=true` For example: warning XA1040: The NativeAOT runtime on Android is an experimental feature and not yet suitable for production use. File issues at: https://github.com/dotnet/android/issues If desired, you can opt out of the warning completely with `$(EnablePreviewFeatures)=true`, or use existing MSBuild mechanisms to suppress it.
MonoVM is currently the default (and supported!) runtime for .NET for Android. Emit
XA1040
when the user opts into using the experimental runtimes, such as:$(UseMonoRuntime)=false
CoreCLR$(PublishAot)=true
NativeAOTIf desired, you can opt out of the warning completely with
$(AndroidAllowExperimentalRuntime)=true
, or use existing MSBuild mechanisms to suppress it.