URL:
https://svn.lrde.epita.fr/svn/scool/branches/scool-ng
ChangeLog:
2009-02-12 Vincent Ordy <ordy(a)lrde.epita.fr>
Fix test sample_1.
* tests/examples/scool_src/sample_1.scl: variable i is const, cannot
modify it.
* tests/examples/c++_src/sample_1.cc,
* tests/examples/c++_ast/sample_1.aterm,
* tests/examples/scool_ast/sample_1.aterm: Adjust.
---
c++_ast/sample_1.aterm | 2 +-
c++_src/sample_1.cc | 1 -
scool_ast/sample_1.aterm | 2 +-
scool_src/sample_1.scl | 1 -
4 files changed, 2 insertions(+), 4 deletions(-)
Index: branches/scool-ng/tests/examples/c++_ast/sample_1.aterm
===================================================================
--- branches/scool-ng/tests/examples/c++_ast/sample_1.aterm (revision 138)
+++ branches/scool-ng/tests/examples/c++_ast/sample_1.aterm (revision 139)
@@ -1 +1 @@
-CxxProgram([CxxFun([],CxxType("void"),CxxId("f"),[],None,[CxxDecl(CxxConstType(CxxType("int")),CxxId("i"),CxxInt("3")),CxxExpStm(CxxAssign(CxxId("i"),CxxInt("4"))),CxxDecl(CxxType("int"),CxxId("j"),CxxInt("3")),CxxExpStm(CxxAssign(CxxId("j"),CxxInt("4")))])])
+CxxProgram([CxxFun([],CxxType("void"),CxxId("f"),[],None,[CxxDecl(CxxConstType(CxxType("int")),CxxId("i"),CxxInt("3")),CxxDecl(CxxType("int"),CxxId("j"),CxxInt("3")),CxxExpStm(CxxAssign(CxxId("j"),CxxInt("4")))])])
Index: branches/scool-ng/tests/examples/c++_src/sample_1.cc
===================================================================
--- branches/scool-ng/tests/examples/c++_src/sample_1.cc (revision 138)
+++ branches/scool-ng/tests/examples/c++_src/sample_1.cc (revision 139)
@@ -1,7 +1,6 @@
void f()
{
const int i = 3;
- i = 4;
int j = 3;
j = 4;
}
Index: branches/scool-ng/tests/examples/scool_ast/sample_1.aterm
===================================================================
--- branches/scool-ng/tests/examples/scool_ast/sample_1.aterm (revision 138)
+++ branches/scool-ng/tests/examples/scool_ast/sample_1.aterm (revision 139)
@@ -1 +1 @@
-Program([FunctionDefinition(None,Identifier("f"),FunctionType(None,ArgumentsDeclaration([]),SimpleType("void")),FunctionBlock([SimpleDeclaration(None,Identifier("i"),SimpleType("int"),Some(Initialiser(Integer("3")))),ExpressionStatement(Assign(Identifier("i"),Integer("4"))),SimpleDeclaration(Some("var"),Identifier("j"),SimpleType("int"),Some(Initialiser(Integer("3")))),ExpressionStatement(Assign(Identifier("j"),Integer("4")))]))])
+Program([FunctionDefinition(None,Identifier("f"),FunctionType(None,ArgumentsDeclaration([]),SimpleType("void")),FunctionBlock([SimpleDeclaration(None,Identifier("i"),SimpleType("int"),Some(Initialiser(Integer("3")))),SimpleDeclaration(Some("var"),Identifier("j"),SimpleType("int"),Some(Initialiser(Integer("3")))),ExpressionStatement(Assign(Identifier("j"),Integer("4")))]))])
Index: branches/scool-ng/tests/examples/scool_src/sample_1.scl
===================================================================
--- branches/scool-ng/tests/examples/scool_src/sample_1.scl (revision 138)
+++ branches/scool-ng/tests/examples/scool_src/sample_1.scl (revision 139)
@@ -2,7 +2,6 @@
f : () -> void =
{
i : int = 3;
- i = 4;
var j : int = 3;
j = 4;