Documentation

LeanGccJit.Core.Struct

Struct is used to construct customized composite types.

See also:

@[extern lean_gcc_jit_context_new_struct_type]

Construct a new struct type, with the given name and fields.

@[extern lean_gcc_jit_context_new_opaque_struct]

Construct a new struct type, with the given name, but without specifying the fields.

The fields can be omitted (in which case the size of the struct is not known), or later specified using LeanGccJit.Core.Struct.setFields.

@[extern lean_gcc_jit_struct_as_type]

Upcast from Struct to JitType.

@[extern lean_gcc_jit_struct_set_fields]

Populate the fields of a formerly-opaque struct type.

This can only be called once on a given struct type.

@[extern lean_gcc_jit_struct_get_field]

Get a struct field by index.

@[extern lean_gcc_jit_struct_get_field_count]

Get the number of fields in the struct.