pub struct SymbolMap<T> { /* private fields */ }
Expand description
Use this to associate additional state with a Symbol, identified by a SymbolId.
We prefer this instead of adding an extra generic state field on Symbol, as that would require propagating the generic type everywhere.
Use as many of these as desired. To allow for initialisation and referencing without Option, the state value must have a default.
The returned type after indexing.
Performs the indexing (
container[index]
) operation.
Read more
Performs the mutable indexing (
container[index]
) operation.
Read more
Immutably borrows from an owned value.
Read more
Mutably borrows from an owned value.
Read more
Returns the argument unchanged.
Calls U::from(self)
.
That is, this conversion is whatever the implementation of
From<T> for U
chooses to do.
The type returned in the event of a conversion error.
Performs the conversion.
The type returned in the event of a conversion error.
Performs the conversion.