UnsafeHashMap.require

Looks up a key's entry, inserting one if not found (may rehash).

  1. Value require(Key key, const(Create) create, err_t error)
  2. Value require(Key key, const(Create) create)
    struct UnsafeHashMap(Key, Value)
    Value
    require
    (
    Create
    )
    (
    Key key
    ,
    auto ref const(Create) create
    )

Parameters

key Key

Key being looked up and stored in the table.

create const(Create)

Called to construct a new value if the key isn't in the table.

Return Value

Type: Value

The entry's final value (or its .init in case of failure).