System.Reflection.Emit.OpCodes.Throw Field

Throws the exception object currently on the evaluation stack.

Syntax

public static readonly OpCode Throw

Remarks

The following table lists the instruction's hexadecimal and Microsoft Intermediate Language (MSIL) assembly format, along with a brief reference summary:

7A

throw

Throws an exception.

The stack transitional behavior, in sequential order, is:

[The 'ordered' type of list has not been implemented in the ECMA stylesheet.]

The throw instruction throws the exception object (type O) currently on the stack.

NullReferenceException is thrown if the object reference is a null reference.

The following ILGenerator.Emit(OpCode) method overload can use the throw opcode:

  • ILGenerator.Emit(OpCode)

Requirements

Namespace: System.Reflection.Emit
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0, 4.0.0.0