Test case for #6483
This commit is contained in:
parent
7af659cf59
commit
e07a256f74
1 changed files with 31 additions and 0 deletions
31
tests/errmsgs/t6483.nim
Normal file
31
tests/errmsgs/t6483.nim
Normal file
|
|
@ -0,0 +1,31 @@
|
||||||
|
discard """
|
||||||
|
errormsg: "request to generate code for .compileTime proc: newSeq"
|
||||||
|
line: 21
|
||||||
|
"""
|
||||||
|
|
||||||
|
type
|
||||||
|
VarItem = object
|
||||||
|
onode: NimNode
|
||||||
|
nnode: NimNode
|
||||||
|
suffix: string
|
||||||
|
|
||||||
|
VarState = object
|
||||||
|
scopes: seq[VarScope]
|
||||||
|
|
||||||
|
VarScope = object
|
||||||
|
variables: seq[VarItem]
|
||||||
|
children: seq[VarScope]
|
||||||
|
|
||||||
|
when isMainModule:
|
||||||
|
var scope1 = VarScope(
|
||||||
|
variables: newSeq[VarItem](),
|
||||||
|
children: newSeq[VarScope]()
|
||||||
|
)
|
||||||
|
var scope2 = VarScope(
|
||||||
|
variables: newSeq[VarItem](),
|
||||||
|
children: newSeq[VarScope]()
|
||||||
|
)
|
||||||
|
var state = VarState(scopes: newSeq[VarScope]())
|
||||||
|
state.scopes.add(scope1)
|
||||||
|
state.scopes[0].children.add(scope2)
|
||||||
|
echo($state.scopes)
|
||||||
Loading…
Add table
Add a link
Reference in a new issue