Skip to content

GenCallSite

1 min read

Import: import system.codegen;

GenCallSite

A call of one of the generator's @on_call functions.

public class GenCallSite

id

Identity of this model node; pass it to GenContext.error_at to report a diagnostic here.

public id: string

callee

Identity of the callee (compare with declof(Json.serialize)).

public callee: string

type_args

Concrete type arguments, in parameter order.

public type_args: List<GenTypeRef>

arg_types

Statically known argument types (TypeRefKind.Unknown when not inferable).

public arg_types: List<GenTypeRef>

location

Where the call is written in source.

public location: GenLocation

constructor

Creates a GenCallSite from its parts. Generators normally receive these from GenContext rather than constructing them.

public constructor(
    id: string,
    callee: string,
    type_args: List<GenTypeRef>,
    arg_types: List<GenTypeRef>,
    location: GenLocation
)