Expand Minimize

MethodImplOptions Enumeration

July 28, 2014

This API supports the .NET Framework infrastructure and is not intended to be used directly from your code.

Defines the details of how a method is implemented.

This enumeration has a FlagsAttribute attribute that allows a bitwise combination of its member values.

Namespace:  System.Runtime.CompilerServices
Assembly:  mscorlib (in mscorlib.dll)

[FlagsAttribute]
public enum MethodImplOptions

Member nameDescription
AggressiveInliningThe method should be inlined if possible.
ForwardRefSpecifies that the method is declared, but its implementation is provided elsewhere.
InternalCallSpecifies an internal call. An internal call is a call to a method implemented within the common language runtime itself.
NoInliningSpecifies that the method can not be inlined. Inlining is an optimization by which a method call is replaced with the method body.
NoOptimizationSpecifies that the method is not optimized by the just-in-time (JIT) compiler.
PreserveSigSpecifies that the method signature is exported exactly as declared.
SynchronizedSpecifies that the method can be executed by only one thread at a time.
UnmanagedSpecifies that the method is implemented in unmanaged code.

Version Notes

Windows Phone

 Specifying the Synchronized option for the MethodImplAttribute constructor is not supported and will not result in synchronized behavior.

Windows Phone OS

Supported in: 8.1, 8.0, 7.1, 7.0

Windows Phone

Show:
© 2014 Microsoft