Skip to main content

Mojo function

get_type_name

get_type_name[type: AnyType, *, qualified_builtins: Bool = False]() -> StaticString

Returns the struct name of the given type parameter.

Parameters:

  • type (AnyType): A mojo type.
  • qualified_builtins (Bool): Whether to print fully qualified builtin type names (e.g. std.builtin.int.Int) or shorten them (e.g. Int).

Returns:

StaticString: Type name.

Was this page helpful?