andyferris / Dictionaries.jl

An alternative interface for dictionaries in Julia, for improved productivity and performance
Other
282 stars 28 forks source link

remove convertability requirement in get #93

Closed piever closed 2 years ago

piever commented 2 years ago

Fix #92. This makes the interface

function gettoken(dict::AbstractDictionary, token) end

and removes the need for conversion. The conversion is kept for modifying methods (such as get!), as in that case one needs to be able to add the index. This is consistent with how Julia Base does it, see eg get! (with conversion) and get (without conversion).