[bcl] Make mono cas opt-in features instead of opt-out for mobile profiles
[mono.git] / mcs / class / referencesource / mscorlib / system / rttype.cs
index 5e3d732b8e237f2a3852d83b798ff2b15eb6bea3..b1b8e3e48f4f9b142298c47a377a88da38130a6c 100644 (file)
@@ -5328,7 +5328,7 @@ namespace System
                             throw new MissingMethodException(Environment.GetResourceString("MissingConstructor_Name", FullName));
                         }
 
-#if !DISABLE_CAS_USE
+#if FEATURE_MONO_CAS
                         // If we're creating a delegate, we're about to call a
                         // constructor taking an integer to represent a target
                         // method. Since this is very difficult (and expensive)
@@ -5359,7 +5359,7 @@ namespace System
                             new SecurityPermission(SecurityPermissionFlag.UnmanagedCode).Demand();
 #endif // FEATURE_CORECLR
                         }
-#endif // !DISABLE_CAS_USE
+#endif // FEATURE_MONO_CAS
                         if (invokeMethod.GetParametersNoCopy().Length == 0)
                         {
                             if (args.Length != 0)