Module types

Source

Structs§

ClosureTypeLongId
A type id of a closure function.
ConcreteEnumId
ConcreteEnumLongId
ConcreteExternTypeId
ConcreteExternTypeLongId
ConcreteStructId
ConcreteStructLongId
ImplTypeById
A wrapper around ImplTypeById that implements Ord for saving in an ordered collection.
ImplTypeId
An impl item of kind type.
TypeId
TypeInfo

Enums§

ConcreteTypeId
TypeHead
Head of a type.
TypeLongId
TypeSizeInformation

Functions§

add_type_based_diagnostics
Adds diagnostics for a type, post semantic analysis of types.
extract_fixed_size_array_size
Extracts the size of a fixed size array, or none if the size is missing. Reports an error if the size is not a numeric literal.
generic_type_generic_params
Query implementation of crate::db::SemanticGroup::generic_type_generic_params.
get_impl_at_context
Checks if there is at least one impl that can be inferred for a specific concrete trait.
maybe_resolve_type
peel_snapshots
Peels all wrapping Snapshot (@) from the type. Returns the number of peeled snapshots and the inner type.
peel_snapshots_ex
Same as peel_snapshots, but takes a TypeLongId instead of a TypeId.
priv_type_is_fully_concrete
priv_type_is_var_free
priv_type_short_name
resolve_type
Resolves a type given a module and a path. Used for resolving from non-statement context.
resolve_type_with_environment
Resolves a type given a module and a path. statement_env should be provided if called from statement context.
single_value_type
Query implementation of crate::db::SemanticGroup::single_value_type.
type_info
Query implementation of crate::db::SemanticGroup::type_info.
type_size_info
Query implementation of crate::db::SemanticGroup::type_size_info.
type_size_info_cycle
Cycle handling of crate::db::SemanticGroup::type_size_info.
verify_fixed_size_array_size
Verifies that a given fixed size array size is within limits, and adds a diagnostic if not.
wrap_in_snapshots
Wraps a type with Snapshot (@) n_snapshots times.