Std.LruCache.put
1 declaration
fn
put: &Std.LruCache.LruCache[K, V] -> K -> V -> Std.LruCache.LruCache[K, V]This is a callable function.
What it does
The cache with an entry added or replaced, and marked as the most recently
used.
Writing is using, so an existing key moves to the end of the order rather
than staying where it was — which is the opposite of LinkedMap.insert and
the reason this is a different type rather than a wrapper.
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.
