File tree 1 file changed +12
-7
lines changed
snap-compile/src/test/java/org/snapscript/compile
1 file changed +12
-7
lines changed Original file line number Diff line number Diff line change @@ -52,14 +52,18 @@ public class ArrayCoercionTest extends TestCase {
52
52
" }\n " +
53
53
"}\n " +
54
54
"var array1: Score[] = [new Score(1.1), new Score(1.0), new Score(2.0)];\n " +
55
- "// var list1: [] = array1;\n " +
56
- "// var array2: [] = list1 ;\n " +
57
- "// var list2: [] = array2 ;\n " +
55
+ "var array2: Comparable [] = array1;\n " +
56
+ "var array3: Score [] = array2 ;\n " +
57
+ "var array4: Comparable [] = array3 ;\n " +
58
58
"\n " +
59
- "println(array1);\n " +
60
- "//println(list1);\n " +
61
- "//println(array2);\n " +
62
- "//println(list2);\n " ;
59
+ "println(array1);\n " +
60
+ "println(array1.class);\n " +
61
+ "println(array2);\n " +
62
+ "println(array2.class);\n " +
63
+ "println(array3);\n " +
64
+ "println(array3.class);\n " +
65
+ "println(array4);\n " +
66
+ "println(array4.class);\n " ;
63
67
64
68
public void testArrayCoercion () throws Exception {;
65
69
Compiler compiler = ClassPathCompilerBuilder .createCompiler ();
@@ -70,6 +74,7 @@ public class ArrayCoercionTest extends TestCase {
70
74
public void testScopeArrayCoercion () throws Exception {;
71
75
Compiler compiler = ClassPathCompilerBuilder .createCompiler ();
72
76
Executable executable = compiler .compile (SOURCE_2 );
77
+ System .err .println (SOURCE_2 );
73
78
executable .execute ();
74
79
}
75
80
}
You can’t perform that action at this time.
0 commit comments