You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
import lib
var x =newSeq[int](1)
echotypeof(x)
let c = x[0]
echotypeof(c)
Current Output
please check whether the problem still exists in git head before posting,
see rebuilding the compiler.
seq[Hidden]
Hidden
Expected Output
seq[int]
int
unearthed by https://forum.nim-lang.org/t/8561
caused user no end of confusion when an unexported (and undocumented) type in a dependency of a dependency was being printed in an error message.
behaviour exist in 1.6,1.4,1.2,1.0,0.20...
$ nim -v
Nim Compiler Version 1.7.1 [Linux: amd64]
Compiled at 2021-10-30
Copyright (c) 2006-2021 by Andreas Rumpf
More and more I'm off the opinion that we should "cache" generic instantiations only so far as required to prevent endless recursions in instantiations and then in a pre-linking step merge duplicated instantiations. This is what Borland C++ did with C++ templates and I don't remember complaints. It's conceptually simple and worked well.
Example
lib.nim
main.nim
Current Output
please check whether the problem still exists in git head before posting,
see rebuilding the compiler.
Expected Output
unearthed by https://forum.nim-lang.org/t/8561
caused user no end of confusion when an unexported (and undocumented) type in a dependency of a dependency was being printed in an error message.
behaviour exist in 1.6,1.4,1.2,1.0,0.20...
Nim Compiler Version 1.7.1 [Linux: amd64]
Compiled at 2021-10-30
Copyright (c) 2006-2021 by Andreas Rumpf
git hash: f755e45
The text was updated successfully, but these errors were encountered: