Show / Hide Table of Contents

    Class ExceptionIntrinsics

    Supports creating, recognizing and parsing exception handling intrinsics.

    Inheritance
    System.Object
    ExceptionIntrinsics
    Inherited Members
    System.Object.ToString()
    System.Object.Equals(System.Object)
    System.Object.Equals(System.Object, System.Object)
    System.Object.ReferenceEquals(System.Object, System.Object)
    System.Object.GetHashCode()
    System.Object.GetType()
    System.Object.MemberwiseClone()
    Namespace: Flame.Compiler.Instructions
    Assembly: Flame.Compiler.dll
    Syntax
    public static class ExceptionIntrinsics

    Fields

    | Improve this Doc View Source

    Namespace

    The namespace for exception handling intrinsics.

    Declaration
    public static readonly IntrinsicNamespace Namespace
    Field Value
    Type Description
    IntrinsicNamespace

    Methods

    | Improve this Doc View Source

    CreateCapturePrototype(IType, IType)

    Creates a 'capture' instruction prototype, which captures a (thrown) exception.

    Declaration
    public static IntrinsicPrototype CreateCapturePrototype(IType resultType, IType argumentType)
    Parameters
    Type Name Description
    IType resultType

    The type of a captured exception.

    IType argumentType

    The type of the exception to capture.

    Returns
    Type Description
    IntrinsicPrototype

    A 'capture' instruction prototype.

    | Improve this Doc View Source

    CreateGetCapturedExceptionPrototype(IType, IType)

    Creates a 'get_captured_exception' instruction prototype, which extracts the exception captured by a captured exception.

    Declaration
    public static IntrinsicPrototype CreateGetCapturedExceptionPrototype(IType resultType, IType argumentType)
    Parameters
    Type Name Description
    IType resultType

    The type of the exception value returned by this operation.

    IType argumentType

    The type of the captured exception to examine.

    Returns
    Type Description
    IntrinsicPrototype

    A 'get_captured_exception' instruction prototype.

    | Improve this Doc View Source

    CreatePrototype(String, IType, IReadOnlyList<IType>)

    Creates an exception handling intrinsic prototype.

    Declaration
    public static IntrinsicPrototype CreatePrototype(string operatorName, IType resultType, IReadOnlyList<IType> parameterTypes)
    Parameters
    Type Name Description
    System.String operatorName

    The name of the operator represented by the exception handling intrinsic.

    IType resultType

    The type of value produced by the intrinsic to create.

    System.Collections.Generic.IReadOnlyList<IType> parameterTypes

    The types of the values the intrinsic takes as arguments.

    Returns
    Type Description
    IntrinsicPrototype

    An exception handling intrinsic prototype.

    | Improve this Doc View Source

    CreateRethrowPrototype(IType)

    Creates a 'rethrow' instruction prototype, which rethrows a captured exception. The difference between 'rethrow' and 'throw' is that the former takes a captured exception and retains stack trace information whereas the latter takes a (raw) exception value and constructs a new stack trace.

    Declaration
    public static IntrinsicPrototype CreateRethrowPrototype(IType capturedExceptionType)
    Parameters
    Type Name Description
    IType capturedExceptionType

    The type of the captured exception to rethrow.

    Returns
    Type Description
    IntrinsicPrototype

    A 'rethrow' intrinsic.

    | Improve this Doc View Source

    CreateThrowPrototype(IType)

    Creates a 'throw' instruction prototype, which throws an exception.

    Declaration
    public static IntrinsicPrototype CreateThrowPrototype(IType exceptionType)
    Parameters
    Type Name Description
    IType exceptionType

    The type of exception to throw.

    Returns
    Type Description
    IntrinsicPrototype

    A 'throw' instruction prototype.

    • Improve this Doc
    • View Source
    Back to top Generated by DocFX