Nim
Nim copied to clipboard
remove `var` for ref parameters in `std/tables`
ref https://github.com/nim-lang/Nim/pull/2139
It seems that it was probably caused by copy pasting.
The PR makes hasKeyOrPut
accept immutable refs like mgetOrPut does. It should does less harm in breaking changes' regard. Though it can probably break something if people pass it to function parameters.
No other procs in tables disallow immutable refs.
Thanks for your hard work on this PR! The lines below are statistics of the Nim compiler built from ea44c5cfed21951feb5978b74fbc6cdb24f54ac2
Hint: mm: orc; threads: on; opt: speed; options: -d:release 163880 lines; 12.366s; 840.68MiB peakmem