From b0ce0ea46ce04d7edc9d2f7a3454cddf3aaaad72 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Tue, 30 Jun 2026 12:50:51 +0000 Subject: [PATCH 1/5] Bump external/Java.Interop from `8d54473` to `6ec1345` Bumps [external/Java.Interop](https://github.com/dotnet/java-interop) from `8d54473` to `6ec1345`. - [Commits](https://github.com/dotnet/java-interop/compare/8d544738ad294b4faf13d189eeeb02f0313e00b3...6ec1345165fa7385c935f16ccaa8cc38be50a080) --- updated-dependencies: - dependency-name: external/Java.Interop dependency-version: 6ec1345165fa7385c935f16ccaa8cc38be50a080 dependency-type: direct:production ... Signed-off-by: dependabot[bot] --- external/Java.Interop | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/external/Java.Interop b/external/Java.Interop index 8d544738ad2..6ec1345165f 160000 --- a/external/Java.Interop +++ b/external/Java.Interop @@ -1 +1 @@ -Subproject commit 8d544738ad294b4faf13d189eeeb02f0313e00b3 +Subproject commit 6ec1345165fa7385c935f16ccaa8cc38be50a080 From 871a9450d1b8e4ccbda43298c57eefe361d9b21d Mon Sep 17 00:00:00 2001 From: Jonathan Peppers Date: Tue, 30 Jun 2026 08:09:02 -0500 Subject: [PATCH 2/5] Remove Java.Runtime.Environment project from solution The Java.Runtime.Environment project was removed upstream in dotnet/java-interop#1447 (commit 4e142449), so the reference in Xamarin.Android.sln no longer resolves and breaks restore. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- Xamarin.Android.sln | 15 --------------- 1 file changed, 15 deletions(-) diff --git a/Xamarin.Android.sln b/Xamarin.Android.sln index f93e6403d70..03f06938fb5 100644 --- a/Xamarin.Android.sln +++ b/Xamarin.Android.sln @@ -133,8 +133,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Java.Interop.Tools.JavaType EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "relnote-gen", "tools\relnote-gen\relnote-gen.csproj", "{D8E14B43-E929-4C18-9FA6-2C3DC47EFC17}" EndProject -Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Java.Runtime.Environment", "external\Java.Interop\src\Java.Runtime.Environment\Java.Runtime.Environment.csproj", "{C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}" -EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "create-android-api", "build-tools\create-android-api\create-android-api.csproj", "{BA4D889D-066B-4C2C-A973-09E319CBC396}" EndProject Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Xamarin.Android.Tools.Aidl-Tests", "tests\Xamarin.Android.Tools.Aidl-Tests\Xamarin.Android.Tools.Aidl-Tests.csproj", "{A39B6D7C-6616-40D6-8AE4-C6CEE93D2708}" @@ -879,18 +877,6 @@ Global {D8E14B43-E929-4C18-9FA6-2C3DC47EFC17}.Release|x64.Build.0 = Release|Any CPU {D8E14B43-E929-4C18-9FA6-2C3DC47EFC17}.Release|x86.ActiveCfg = Release|Any CPU {D8E14B43-E929-4C18-9FA6-2C3DC47EFC17}.Release|x86.Build.0 = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|Any CPU.Build.0 = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|x64.ActiveCfg = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|x64.Build.0 = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|x86.ActiveCfg = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Debug|x86.Build.0 = Debug|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|Any CPU.ActiveCfg = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|Any CPU.Build.0 = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|x64.ActiveCfg = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|x64.Build.0 = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|x86.ActiveCfg = Release|Any CPU - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B}.Release|x86.Build.0 = Release|Any CPU {BA4D889D-066B-4C2C-A973-09E319CBC396}.Debug|Any CPU.ActiveCfg = Debug|Any CPU {BA4D889D-066B-4C2C-A973-09E319CBC396}.Debug|Any CPU.Build.0 = Debug|Any CPU {BA4D889D-066B-4C2C-A973-09E319CBC396}.Debug|x64.ActiveCfg = Debug|Any CPU @@ -1097,7 +1083,6 @@ Global {DA50FC92-7FE7-48B5-BDB6-CDA57B37BB51} = {864062D3-A415-4A6F-9324-5820237BA058} {4EFCED6E-9A6B-453A-94E4-CE4B736EC684} = {864062D3-A415-4A6F-9324-5820237BA058} {D8E14B43-E929-4C18-9FA6-2C3DC47EFC17} = {864062D3-A415-4A6F-9324-5820237BA058} - {C0E44558-FEE3-4DD3-986A-3F46DD1BF41B} = {04E3E11E-B47D-4599-8AFC-50515A95E715} {BA4D889D-066B-4C2C-A973-09E319CBC396} = {E351F97D-EA4F-4E7F-AAA0-8EBB1F2A4A62} {A39B6D7C-6616-40D6-8AE4-C6CEE93D2708} = {CAB438D8-B0F5-4AF0-BEBD-9E2ADBD7B483} {5E806C9F-1B67-4B6B-A6AB-258834250DBB} = {FFCF518F-2A4A-40A2-9174-2EE13B76C723} From 871a29266facfc0b1bdcd5574bea9408c974c0ef Mon Sep 17 00:00:00 2001 From: Jonathan Peppers Date: Tue, 30 Jun 2026 10:00:54 -0500 Subject: [PATCH 3/5] Migrate ManagedTypeManager.RegisterNativeMembers to blittable RegisterNatives Upstream dotnet/java-interop#1474 added [RequiresDynamicCode] to the JniNativeMethodRegistration[] overload of JniEnvironment.Types.RegisterNatives, which makes ManagedTypeManager.RegisterNativeMembers emit IL3050 under NativeAOT. Marshal directly into blittable JniNativeMethod values (UTF-8 strings via Marshal.StringToCoTaskMemUTF8 + Marshal.GetFunctionPointerForDelegate) and call the blittable RegisterNatives(JniObjectReference, ReadOnlySpan) overload to eliminate the warning. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../ManagedTypeManager.cs | 102 +++++++++++------- 1 file changed, 64 insertions(+), 38 deletions(-) diff --git a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs index db254b65bb8..80f3bd58e2f 100644 --- a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs +++ b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs @@ -2,6 +2,7 @@ using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using System.Reflection; +using System.Runtime.InteropServices; using Java.Interop; using Java.Interop.Tools.TypeNameMappings; @@ -45,7 +46,7 @@ public ManagedTypeManager () [UnconditionalSuppressMessage ("Trimming", "IL2057", Justification = "Type.GetType() can never statically know the string value parsed from parameter 'methods'.")] [UnconditionalSuppressMessage ("Trimming", "IL2067", Justification = "Delegate.CreateDelegate() can never statically know the string value parsed from parameter 'methods'.")] [UnconditionalSuppressMessage ("Trimming", "IL2072", Justification = "Delegate.CreateDelegate() can never statically know the string value parsed from parameter 'methods'.")] - public override void RegisterNativeMembers ( + public override unsafe void RegisterNativeMembers ( JniType nativeClass, Type type, ReadOnlySpan methods) @@ -61,51 +62,76 @@ public override void RegisterNativeMembers ( return; } - JniNativeMethodRegistration [] natives = new JniNativeMethodRegistration [methodCount]; + // Marshal directly into blittable JniNativeMethod values and dispatch to the blittable + // RegisterNatives overload, instead of the JniNativeMethodRegistration[] overload (which + // is annotated [RequiresDynamicCode] and works around a crossgen2 miscompilation by + // performing the same marshaling internally). See dotnet/java-interop#1474. + const int MaxStackAllocatedNativeMethods = 32; + bool useStackAllocatedBuffers = methodCount <= MaxStackAllocatedNativeMethods; + Span natives = useStackAllocatedBuffers + ? stackalloc JniNativeMethod [methodCount] + : new JniNativeMethod [methodCount]; + Span unmanagedStrings = useStackAllocatedBuffers + ? stackalloc IntPtr [methodCount * 2] + : new IntPtr [methodCount * 2]; + unmanagedStrings.Clear (); + // Keep marshaler delegates alive at least until JNI has consumed the function pointers. + Delegate? [] callbacks = new Delegate? [methodCount]; int nativesIndex = 0; - ReadOnlySpan methodsSpan = methods; - bool needToRegisterNatives = false; - - while (!methodsSpan.IsEmpty) { - int newLineIndex = methodsSpan.IndexOf ('\n'); - - ReadOnlySpan methodLine = methodsSpan.Slice (0, newLineIndex != -1 ? newLineIndex : methodsSpan.Length); - if (!methodLine.IsEmpty) { - SplitMethodLine (methodLine, - out ReadOnlySpan name, - out ReadOnlySpan signature, - out ReadOnlySpan callbackString, - out ReadOnlySpan callbackDeclaringTypeString); - - Delegate? callback = null; - if (callbackString.SequenceEqual ("__export__")) { - throw new InvalidOperationException (FormattableString.Invariant ($"Methods such as {callbackString.ToString ()} are not implemented!")); - } else { - Type callbackDeclaringType = type; - if (!callbackDeclaringTypeString.IsEmpty) { - callbackDeclaringType = Type.GetType (callbackDeclaringTypeString.ToString (), throwOnError: true)!; - } - while (callbackDeclaringType.ContainsGenericParameters) { - callbackDeclaringType = callbackDeclaringType.BaseType!; + try { + ReadOnlySpan methodsSpan = methods; + while (!methodsSpan.IsEmpty) { + int newLineIndex = methodsSpan.IndexOf ('\n'); + + ReadOnlySpan methodLine = methodsSpan.Slice (0, newLineIndex != -1 ? newLineIndex : methodsSpan.Length); + if (!methodLine.IsEmpty) { + SplitMethodLine (methodLine, + out ReadOnlySpan name, + out ReadOnlySpan signature, + out ReadOnlySpan callbackString, + out ReadOnlySpan callbackDeclaringTypeString); + + Delegate? callback = null; + if (callbackString.SequenceEqual ("__export__")) { + throw new InvalidOperationException (FormattableString.Invariant ($"Methods such as {callbackString.ToString ()} are not implemented!")); + } else { + Type callbackDeclaringType = type; + if (!callbackDeclaringTypeString.IsEmpty) { + callbackDeclaringType = Type.GetType (callbackDeclaringTypeString.ToString (), throwOnError: true)!; + } + while (callbackDeclaringType.ContainsGenericParameters) { + callbackDeclaringType = callbackDeclaringType.BaseType!; + } + + GetCallbackHandler connector = (GetCallbackHandler) Delegate.CreateDelegate (typeof (GetCallbackHandler), + callbackDeclaringType, callbackString.ToString ()); + callback = connector (); } - GetCallbackHandler connector = (GetCallbackHandler) Delegate.CreateDelegate (typeof (GetCallbackHandler), - callbackDeclaringType, callbackString.ToString ()); - callback = connector (); + if (callback != null) { + IntPtr namePtr = Marshal.StringToCoTaskMemUTF8 (name.ToString ()); + unmanagedStrings [nativesIndex * 2] = namePtr; + IntPtr sigPtr = Marshal.StringToCoTaskMemUTF8 (signature.ToString ()); + unmanagedStrings [nativesIndex * 2 + 1] = sigPtr; + callbacks [nativesIndex] = callback; + natives [nativesIndex] = new JniNativeMethod ((byte*) namePtr, (byte*) sigPtr, Marshal.GetFunctionPointerForDelegate (callback)); + nativesIndex++; + } } - if (callback != null) { - needToRegisterNatives = true; - natives [nativesIndex++] = new JniNativeMethodRegistration (name.ToString (), signature.ToString (), callback); - } + methodsSpan = newLineIndex != -1 ? methodsSpan.Slice (newLineIndex + 1) : default; } - methodsSpan = newLineIndex != -1 ? methodsSpan.Slice (newLineIndex + 1) : default; - } - - if (needToRegisterNatives) { - JniEnvironment.Types.RegisterNatives (nativeClass.PeerReference, natives, nativesIndex); + if (nativesIndex > 0) { + JniEnvironment.Types.RegisterNatives (nativeClass.PeerReference, natives.Slice (0, nativesIndex)); + GC.KeepAlive (callbacks); + } + } finally { + for (int i = 0; i < unmanagedStrings.Length; ++i) { + if (unmanagedStrings [i] != IntPtr.Zero) + Marshal.ZeroFreeCoTaskMemUTF8 (unmanagedStrings [i]); + } } } From 6ca40e95e684235e6f2a38cdf74f74a127fdd731 Mon Sep 17 00:00:00 2001 From: Jonathan Peppers Date: Tue, 30 Jun 2026 10:07:12 -0500 Subject: [PATCH 4/5] Suppress new IL3050 warnings in ManagedTypeManager Upstream dotnet/java-interop#1474 added [RequiresDynamicCode] to: - JniRuntime.ReflectionJniTypeManager (the class), surfacing IL3050 at ManagedTypeManager..ctor() since we derive from it. - JniEnvironment.Types.RegisterNatives(.., JniNativeMethodRegistration[], int), surfacing IL3050 at ManagedTypeManager.RegisterNativeMembers. Suppress both for now; the JniNativeMethodRegistration[] registration path will be migrated to the blittable RegisterNatives(JniObjectReference, ReadOnlySpan) overload in a future change. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- .../ManagedTypeManager.cs | 104 +++++++----------- 1 file changed, 40 insertions(+), 64 deletions(-) diff --git a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs index 80f3bd58e2f..a3cb109a6a1 100644 --- a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs +++ b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs @@ -2,7 +2,6 @@ using System.Collections.Generic; using System.Diagnostics.CodeAnalysis; using System.Reflection; -using System.Runtime.InteropServices; using Java.Interop; using Java.Interop.Tools.TypeNameMappings; @@ -16,6 +15,7 @@ class ManagedTypeManager : JniRuntime.ReflectionJniTypeManager { internal const DynamicallyAccessedMemberTypes MethodsAndPrivateNested = Methods | DynamicallyAccessedMemberTypes.NonPublicNestedTypes; internal const DynamicallyAccessedMemberTypes MethodsConstructors = MethodsAndPrivateNested | Constructors; + [UnconditionalSuppressMessage ("AOT", "IL3050", Justification = "ManagedTypeManager is the non-NativeAOT JniTypeManager; NativeAOT uses a separate implementation. Will be removed in a future change.")] public ManagedTypeManager () { } @@ -46,7 +46,8 @@ public ManagedTypeManager () [UnconditionalSuppressMessage ("Trimming", "IL2057", Justification = "Type.GetType() can never statically know the string value parsed from parameter 'methods'.")] [UnconditionalSuppressMessage ("Trimming", "IL2067", Justification = "Delegate.CreateDelegate() can never statically know the string value parsed from parameter 'methods'.")] [UnconditionalSuppressMessage ("Trimming", "IL2072", Justification = "Delegate.CreateDelegate() can never statically know the string value parsed from parameter 'methods'.")] - public override unsafe void RegisterNativeMembers ( + [UnconditionalSuppressMessage ("AOT", "IL3050", Justification = "JniNativeMethodRegistration[] registration path will be migrated to the blittable RegisterNatives overload in a future change.")] + public override void RegisterNativeMembers ( JniType nativeClass, Type type, ReadOnlySpan methods) @@ -62,76 +63,51 @@ public override unsafe void RegisterNativeMembers ( return; } - // Marshal directly into blittable JniNativeMethod values and dispatch to the blittable - // RegisterNatives overload, instead of the JniNativeMethodRegistration[] overload (which - // is annotated [RequiresDynamicCode] and works around a crossgen2 miscompilation by - // performing the same marshaling internally). See dotnet/java-interop#1474. - const int MaxStackAllocatedNativeMethods = 32; - bool useStackAllocatedBuffers = methodCount <= MaxStackAllocatedNativeMethods; - Span natives = useStackAllocatedBuffers - ? stackalloc JniNativeMethod [methodCount] - : new JniNativeMethod [methodCount]; - Span unmanagedStrings = useStackAllocatedBuffers - ? stackalloc IntPtr [methodCount * 2] - : new IntPtr [methodCount * 2]; - unmanagedStrings.Clear (); - // Keep marshaler delegates alive at least until JNI has consumed the function pointers. - Delegate? [] callbacks = new Delegate? [methodCount]; + JniNativeMethodRegistration [] natives = new JniNativeMethodRegistration [methodCount]; int nativesIndex = 0; - try { - ReadOnlySpan methodsSpan = methods; - while (!methodsSpan.IsEmpty) { - int newLineIndex = methodsSpan.IndexOf ('\n'); - - ReadOnlySpan methodLine = methodsSpan.Slice (0, newLineIndex != -1 ? newLineIndex : methodsSpan.Length); - if (!methodLine.IsEmpty) { - SplitMethodLine (methodLine, - out ReadOnlySpan name, - out ReadOnlySpan signature, - out ReadOnlySpan callbackString, - out ReadOnlySpan callbackDeclaringTypeString); - - Delegate? callback = null; - if (callbackString.SequenceEqual ("__export__")) { - throw new InvalidOperationException (FormattableString.Invariant ($"Methods such as {callbackString.ToString ()} are not implemented!")); - } else { - Type callbackDeclaringType = type; - if (!callbackDeclaringTypeString.IsEmpty) { - callbackDeclaringType = Type.GetType (callbackDeclaringTypeString.ToString (), throwOnError: true)!; - } - while (callbackDeclaringType.ContainsGenericParameters) { - callbackDeclaringType = callbackDeclaringType.BaseType!; - } - - GetCallbackHandler connector = (GetCallbackHandler) Delegate.CreateDelegate (typeof (GetCallbackHandler), - callbackDeclaringType, callbackString.ToString ()); - callback = connector (); - } + ReadOnlySpan methodsSpan = methods; + bool needToRegisterNatives = false; + + while (!methodsSpan.IsEmpty) { + int newLineIndex = methodsSpan.IndexOf ('\n'); - if (callback != null) { - IntPtr namePtr = Marshal.StringToCoTaskMemUTF8 (name.ToString ()); - unmanagedStrings [nativesIndex * 2] = namePtr; - IntPtr sigPtr = Marshal.StringToCoTaskMemUTF8 (signature.ToString ()); - unmanagedStrings [nativesIndex * 2 + 1] = sigPtr; - callbacks [nativesIndex] = callback; - natives [nativesIndex] = new JniNativeMethod ((byte*) namePtr, (byte*) sigPtr, Marshal.GetFunctionPointerForDelegate (callback)); - nativesIndex++; + ReadOnlySpan methodLine = methodsSpan.Slice (0, newLineIndex != -1 ? newLineIndex : methodsSpan.Length); + if (!methodLine.IsEmpty) { + SplitMethodLine (methodLine, + out ReadOnlySpan name, + out ReadOnlySpan signature, + out ReadOnlySpan callbackString, + out ReadOnlySpan callbackDeclaringTypeString); + + Delegate? callback = null; + if (callbackString.SequenceEqual ("__export__")) { + throw new InvalidOperationException (FormattableString.Invariant ($"Methods such as {callbackString.ToString ()} are not implemented!")); + } else { + Type callbackDeclaringType = type; + if (!callbackDeclaringTypeString.IsEmpty) { + callbackDeclaringType = Type.GetType (callbackDeclaringTypeString.ToString (), throwOnError: true)!; + } + while (callbackDeclaringType.ContainsGenericParameters) { + callbackDeclaringType = callbackDeclaringType.BaseType!; } + + GetCallbackHandler connector = (GetCallbackHandler) Delegate.CreateDelegate (typeof (GetCallbackHandler), + callbackDeclaringType, callbackString.ToString ()); + callback = connector (); } - methodsSpan = newLineIndex != -1 ? methodsSpan.Slice (newLineIndex + 1) : default; + if (callback != null) { + needToRegisterNatives = true; + natives [nativesIndex++] = new JniNativeMethodRegistration (name.ToString (), signature.ToString (), callback); + } } - if (nativesIndex > 0) { - JniEnvironment.Types.RegisterNatives (nativeClass.PeerReference, natives.Slice (0, nativesIndex)); - GC.KeepAlive (callbacks); - } - } finally { - for (int i = 0; i < unmanagedStrings.Length; ++i) { - if (unmanagedStrings [i] != IntPtr.Zero) - Marshal.ZeroFreeCoTaskMemUTF8 (unmanagedStrings [i]); - } + methodsSpan = newLineIndex != -1 ? methodsSpan.Slice (newLineIndex + 1) : default; + } + + if (needToRegisterNatives) { + JniEnvironment.Types.RegisterNatives (nativeClass.PeerReference, natives, nativesIndex); } } From 0ea9fefacabba78576e543782392c1a7e8d58da0 Mon Sep 17 00:00:00 2001 From: Jonathan Peppers Date: Tue, 30 Jun 2026 10:09:07 -0500 Subject: [PATCH 5/5] Revert ctor IL3050 suppression The ReflectionJniTypeManager [RequiresDynamicCode] attribute predates this submodule bump (added in dotnet/java-interop#1441), so the ManagedTypeManager..ctor() IL3050 is already part of the BuildHasNoWarnings test's baseline of 4 warnings. Only the RegisterNativeMembers warning is new from this PR; suppressing the ctor warning too would drop the count to 2 and fail the test. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> --- src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs | 1 - 1 file changed, 1 deletion(-) diff --git a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs index a3cb109a6a1..85768bcc33d 100644 --- a/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs +++ b/src/Mono.Android/Microsoft.Android.Runtime/ManagedTypeManager.cs @@ -15,7 +15,6 @@ class ManagedTypeManager : JniRuntime.ReflectionJniTypeManager { internal const DynamicallyAccessedMemberTypes MethodsAndPrivateNested = Methods | DynamicallyAccessedMemberTypes.NonPublicNestedTypes; internal const DynamicallyAccessedMemberTypes MethodsConstructors = MethodsAndPrivateNested | Constructors; - [UnconditionalSuppressMessage ("AOT", "IL3050", Justification = "ManagedTypeManager is the non-NativeAOT JniTypeManager; NativeAOT uses a separate implementation. Will be removed in a future change.")] public ManagedTypeManager () { }