DictionaryTypeOperator

public type DictionaryTypeOperator[K, V] = Dictionary[K, V, DefaultHasher]

Compiler-recognized type alias that lets [K: V] desugar to Dictionary[K, V, DefaultHasher].

Allows annotations like let m: [String: Int64] = [:] instead of requiring the user to spell out Dictionary[String, Int64]. The hasher is fixed to DefaultHasher; for custom hashers, write the Dictionary[...] form explicitly.

Examples

let counts: [String: Int64] = [:]; func tally(of words: [String: Int64]) -> Int64 { ... }

Defined in lang/std/collections/dictionary.ks