@@ -266,18 +266,16 @@ protected virtual IEnumerable<string> GetSimpleReferences (Type type)
266
266
static readonly Type [ ] EmptyTypeArray = Array . Empty < Type > ( ) ;
267
267
const string NotUsedInAndroid = "This code path is not used in Android projects." ;
268
268
269
+ // FIXME: https://github.com/dotnet/java-interop/issues/1192
270
+ [ UnconditionalSuppressMessage ( "Trimming" , "IL3050" , Justification = NotUsedInAndroid ) ]
269
271
static Type MakeArrayType ( Type type ) =>
270
- // FIXME: https://github.com/dotnet/java-interop/issues/1192
271
- #pragma warning disable IL3050
272
272
type . MakeArrayType ( ) ;
273
- #pragma warning restore IL3050
274
273
274
+ // FIXME: https://github.com/dotnet/java-interop/issues/1192
275
275
[ UnconditionalSuppressMessage ( "Trimming" , "IL2055" , Justification = NotUsedInAndroid ) ]
276
+ [ UnconditionalSuppressMessage ( "Trimming" , "IL3050" , Justification = NotUsedInAndroid ) ]
276
277
static Type MakeGenericType ( Type type , Type arrayType ) =>
277
- // FIXME: https://github.com/dotnet/java-interop/issues/1192
278
- #pragma warning disable IL3050
279
278
type . MakeGenericType ( arrayType ) ;
280
- #pragma warning restore IL3050
281
279
282
280
[ UnconditionalSuppressMessage ( "Trimming" , "IL2073" , Justification = "Types returned here should be preserved via other means." ) ]
283
281
[ return : DynamicallyAccessedMembers ( MethodsConstructors ) ]
@@ -400,16 +398,15 @@ IEnumerable<Type> CreateGetTypesForSimpleReferenceEnumerator (string jniSimpleRe
400
398
// https://github.com/xamarin/xamarin-android/blob/5472eec991cc075e4b0c09cd98a2331fb93aa0f3/src/Microsoft.Android.Sdk.ILLink/MarkJavaObjects.cs#L176-L186
401
399
const string makeGenericTypeMessage = "Generic 'Invoker' types are preserved by the MarkJavaObjects trimmer step." ;
402
400
401
+ // FIXME: https://github.com/dotnet/java-interop/issues/1192
403
402
[ UnconditionalSuppressMessage ( "Trimming" , "IL2055" , Justification = makeGenericTypeMessage ) ]
403
+ [ UnconditionalSuppressMessage ( "Trimming" , "IL3050" , Justification = makeGenericTypeMessage ) ]
404
404
[ return : DynamicallyAccessedMembers ( Constructors ) ]
405
405
static Type MakeGenericType (
406
406
[ DynamicallyAccessedMembers ( Constructors ) ]
407
407
Type type ,
408
408
Type [ ] arguments ) =>
409
- // FIXME: https://github.com/dotnet/java-interop/issues/1192
410
- #pragma warning disable IL3050
411
409
type . MakeGenericType ( arguments ) ;
412
- #pragma warning restore IL3050
413
410
414
411
var signature = type . GetCustomAttribute < JniTypeSignatureAttribute > ( ) ;
415
412
if ( signature == null || signature . InvokerType == null ) {
0 commit comments