RehashingAA.opIndexUnary

Performs a unary operation on a value in the internal associative array.

struct RehashingAA(AA : V[K], V, K)
ref
opIndexUnary
(
string op
)
(
K key
)

Parameters

op

Unary operation as a string.

key K

Key.

Return Value

Type: auto ref

The result of the operation.

Examples

RehashingAA!(int[string]) aa;
aa["abc"] = 123;
writeln(-aa["abc"]);  // -123

Meta