Std.MultiKeyMap.insert
1 declaration
fn
insert: &Std.MultiKeyMap.MultiKeyMap[A, B, V] -> A -> B -> V -> Std.MultiKeyMap.MultiKeyMap[A, B, V]This is a callable function.
What it does
The map with an entry added or replaced.
The indexes only gain an entry when the key is new. Replacing a value leaves
them alone, because the pair they record is unchanged — recording it twice
would make a later removal drop only one of the copies and leave the index
claiming a key the entries no longer hold.
Read the signature
- The text after the name is the type checked by Pudu.
- Read arrows from left to right: inputs come first, and the final type is returned.
- & borrows a value for this call instead of moving or copying it.
- Names inside [ ] are type arguments, such as the item type held by a collection.
