make tests green again

This commit is contained in:
Andreas Rumpf 2017-11-19 20:09:38 +01:00
commit 2ad49836d9
2 changed files with 95 additions and 95 deletions

View file

@ -1,82 +1,82 @@
discard """ discard """
nimout: ''' nimout: '''
StmtList StmtList
Ident !"foo010" Ident ident"foo010"
Call Call
Ident !"foo020" Ident ident"foo020"
Call Call
Ident !"foo030" Ident ident"foo030"
Ident !"x" Ident ident"x"
Command Command
Ident !"foo040" Ident ident"foo040"
Ident !"x" Ident ident"x"
Call Call
Ident !"foo050" Ident ident"foo050"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo060" Ident ident"foo060"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo070" Ident ident"foo070"
StrLit test StrLit test
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo080" Ident ident"foo080"
StrLit test StrLit test
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo090" Ident ident"foo090"
StrLit test StrLit test
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo100" Ident ident"foo100"
Call Call
StrLit test StrLit test
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo101" Ident ident"foo101"
Call Call
IntLit 10 IntLit 10
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo110" Ident ident"foo110"
IntLit 1 IntLit 1
Par Par
Infix Infix
Ident !"+" Ident ident"+"
IntLit 2 IntLit 2
IntLit 3 IntLit 3
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo120" Ident ident"foo120"
IntLit 1 IntLit 1
Call Call
Par Par
Infix Infix
Ident !"+" Ident ident"+"
IntLit 2 IntLit 2
IntLit 3 IntLit 3
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo130" Ident ident"foo130"
Do Do
Empty Empty
Empty Empty
@ -84,7 +84,7 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"x" Ident ident"x"
Empty Empty
Empty Empty
Empty Empty
@ -93,7 +93,7 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo140" Ident ident"foo140"
Do Do
Empty Empty
Empty Empty
@ -101,8 +101,8 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"x" Ident ident"x"
Ident !"int" Ident ident"int"
Empty Empty
Empty Empty
Empty Empty
@ -110,16 +110,16 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo150" Ident ident"foo150"
Do Do
Empty Empty
Empty Empty
Empty Empty
FormalParams FormalParams
Ident !"int" Ident ident"int"
IdentDefs IdentDefs
Ident !"x" Ident ident"x"
Ident !"int" Ident ident"int"
Empty Empty
Empty Empty
Empty Empty
@ -127,9 +127,9 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo160" Ident ident"foo160"
Call Call
Ident !"x" Ident ident"x"
Do Do
Empty Empty
Empty Empty
@ -137,7 +137,7 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"y" Ident ident"y"
Empty Empty
Empty Empty
Empty Empty
@ -146,7 +146,7 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo170" Ident ident"foo170"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
@ -155,7 +155,7 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo180" Ident ident"foo180"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
@ -167,9 +167,9 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Command Command
Ident !"foo190" Ident ident"foo190"
Call Call
Ident !"x" Ident ident"x"
Do Do
Empty Empty
Empty Empty
@ -177,7 +177,7 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"y" Ident ident"y"
Empty Empty
Empty Empty
Empty Empty
@ -190,9 +190,9 @@ StmtList
Empty Empty
Empty Empty
FormalParams FormalParams
Ident !"int" Ident ident"int"
IdentDefs IdentDefs
Ident !"z" Ident ident"z"
Empty Empty
Empty Empty
Empty Empty
@ -205,10 +205,10 @@ StmtList
Empty Empty
Empty Empty
FormalParams FormalParams
Ident !"int" Ident ident"int"
IdentDefs IdentDefs
Ident !"w" Ident ident"w"
Ident !"int" Ident ident"int"
Empty Empty
Empty Empty
Empty Empty
@ -223,10 +223,10 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
Ident !"foo200" Ident ident"foo200"
Ident !"x" Ident ident"x"
Call Call
Ident !"bar" Ident ident"bar"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
@ -236,53 +236,53 @@ StmtList
Empty Empty
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Ident !"foo210" Ident ident"foo210"
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Call Call
Ident !"foo220" Ident ident"foo220"
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Call Call
Ident !"foo230" Ident ident"foo230"
Ident !"x" Ident ident"x"
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Command Command
Ident !"foo240" Ident ident"foo240"
Ident !"x" Ident ident"x"
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Call Call
Ident !"foo250" Ident ident"foo250"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Call Call
Ident !"foo260" Ident ident"foo260"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Call Call
Ident !"foo270" Ident ident"foo270"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
@ -292,12 +292,12 @@ StmtList
Empty Empty
VarSection VarSection
IdentDefs IdentDefs
Ident !"a" Ident ident"a"
Empty Empty
Command Command
Ident !"foo280" Ident ident"foo280"
Call Call
Ident !"x" Ident ident"x"
Do Do
Empty Empty
Empty Empty
@ -305,7 +305,7 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"y" Ident ident"y"
Empty Empty
Empty Empty
Empty Empty
@ -318,40 +318,40 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Asgn Asgn
Ident !"a" Ident ident"a"
Ident !"foo290" Ident ident"foo290"
Asgn Asgn
Ident !"a" Ident ident"a"
Call Call
Ident !"foo300" Ident ident"foo300"
Asgn Asgn
Ident !"a" Ident ident"a"
Call Call
Ident !"foo310" Ident ident"foo310"
Ident !"x" Ident ident"x"
Asgn Asgn
Ident !"a" Ident ident"a"
Command Command
Ident !"foo320" Ident ident"foo320"
Ident !"x" Ident ident"x"
Asgn Asgn
Ident !"a" Ident ident"a"
Call Call
Ident !"foo330" Ident ident"foo330"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Asgn Asgn
Ident !"a" Ident ident"a"
Call Call
Ident !"foo340" Ident ident"foo340"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Asgn Asgn
Ident !"a" Ident ident"a"
Call Call
Ident !"foo350" Ident ident"foo350"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
@ -360,13 +360,13 @@ StmtList
DiscardStmt DiscardStmt
Empty Empty
Asgn Asgn
Ident !"a" Ident ident"a"
Command Command
Ident !"foo360" Ident ident"foo360"
Call Call
DotExpr DotExpr
Ident !"x" Ident ident"x"
Ident !"bar" Ident ident"bar"
Do Do
Empty Empty
Empty Empty
@ -374,7 +374,7 @@ StmtList
FormalParams FormalParams
Empty Empty
IdentDefs IdentDefs
Ident !"y" Ident ident"y"
Empty Empty
Empty Empty
Empty Empty
@ -388,20 +388,20 @@ StmtList
Empty Empty
Command Command
DotExpr DotExpr
Ident !"foo370" Ident ident"foo370"
Ident !"add" Ident ident"add"
Call Call
Ident !"quote" Ident ident"quote"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty
Call Call
DotExpr DotExpr
Ident !"foo380" Ident ident"foo380"
Ident !"add" Ident ident"add"
BracketExpr BracketExpr
Call Call
Ident !"quote" Ident ident"quote"
StmtList StmtList
DiscardStmt DiscardStmt
Empty Empty

View file

@ -26,12 +26,12 @@ proc checkNode(arg: NimNode; name: string): void {. compileTime .} =
seqAppend.add(arg) # bit this creates a copy seqAppend.add(arg) # bit this creates a copy
arg.add newCall(ident"echo", newLit("Hello World")) arg.add newCall(ident"echo", newLit("Hello World"))
assertEq arg.lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq arg.lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
assertEq node.lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq node.lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
assertEq nodeArray[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq nodeArray[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
assertEq nodeSeq[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq nodeSeq[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
assertEq seqAppend[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq seqAppend[0].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
assertEq seqAppend[1].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(!"echo"), StrLit(Hello World)))""" assertEq seqAppend[1].lispRepr , """StmtList(DiscardStmt(Empty()), Call(Ident(ident"echo"), StrLit(Hello World)))"""
echo "OK" echo "OK"