Interface FunctionKindOptions<Specifics>

Options which are relevant for all kinds.

interface FunctionKindOptions<Specifics extends TypirSpecifics> {
    $name: string;
    enforceFunctionName: boolean;
    enforceInputParameterNames: boolean;
    enforceOutputParameterName: boolean;
    identifierPrefix: string;
    subtypeParameterChecking: TypeCheckStrategy;
    typeToInferForCallsOfFunctionsWithoutOutput: TypeDescriptor<
        Type,
        Specifics,
    >;
}

Type Parameters

Hierarchy (View Summary)

Properties

$name: string

Customize the name which is used to register the kind in the kind registry.

enforceFunctionName: boolean
enforceInputParameterNames: boolean
enforceOutputParameterName: boolean
identifierPrefix: string

Will be used only internally as prefix for the unique identifiers for function type names.

subtypeParameterChecking: TypeCheckStrategy
typeToInferForCallsOfFunctionsWithoutOutput: TypeDescriptor<Type, Specifics>

If a function has no output type (e.g. "void" functions), this type is returned during the type inference of calls to these functions. The default value "THROW_ERROR" indicates to throw an error, i.e. type inference for calls of such functions are not allowed.