Wonder why `Table[string, string].init` doesn't work in default arg
initialisation?
import std/tables
proc init*[K, V](_: type[Table[K, V]]): Table[K, V] =
discard
proc somefn(_: type[string], params = Table[string, string].init) =
discard
echo Table[string, string].init # works
string.somefn # doesn't work
Run
- Can't instantiate generic in some cases alexeypetrushin
- Can't instantiate generic in some cases ElegantBeef
- Can't instantiate generic in some cases alexeypetrushin
