diff options
Diffstat (limited to 'chapter25/src/test/java/com/seaofnodes')
| -rw-r--r-- | chapter25/src/test/java/com/seaofnodes/simple/Chapter22Test.java | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/chapter25/src/test/java/com/seaofnodes/simple/Chapter22Test.java b/chapter25/src/test/java/com/seaofnodes/simple/Chapter22Test.java index 68f94f12..96e7fce7 100644 --- a/chapter25/src/test/java/com/seaofnodes/simple/Chapter22Test.java +++ b/chapter25/src/test/java/com/seaofnodes/simple/Chapter22Test.java @@ -231,6 +231,15 @@ return 0; assertEquals("Hello, World!",arm._stdout.toString()); } + + @Test + public void testStrLoad() { + CodeGen code = new CodeGen("return \"abc\"[1];"); + code.parse().opto(); + assertEquals("return .[];", code.print()); + } + + @Test public void testFinalArray() { String src = """ |
