pub const Fn = struct attrs: Attributesis_generic: boolreturn_type: ?typenull means the return type is generic, i.e. it depends on a function argument.
param_types: []const ?typeA null element represents either an anytype parameter, or a parameter with a generic type, i.e. where the type depends on a previous function argument.
param_attrs: []const ParamAttributesGuaranteed to have the same length as param_types.
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868 pub const Fn = struct {
attrs: Attributes,
is_generic: bool,
/// `null` means the return type is generic, i.e. it depends on a function argument.
return_type: ?type,
/// A `null` element represents either an `anytype` parameter, or a parameter with a generic
/// type, i.e. where the type depends on a previous function argument.
param_types: []const ?type,
/// Guaranteed to have the same length as `param_types`.
param_attrs: []const ParamAttributes,
pub const ParamAttributes = struct {
@"noalias": bool = false,
};
pub const Attributes = struct {
@"callconv": CallingConvention = .auto,
varargs: bool = false,
};
}
This data structure is used by the Zig language code generation and therefore must be kept in sync with the compiler implementation.