class Main {
function void main() {
var String foo;
let foo = "bar";
if (foo == "bar") {
do Output.printString("true");
}
else {
do Output.printString("false");
}
return;
}
}
我得到错误:Expected - or ~ or ( in term
。
完整输出:
code/nand2tetris » tools/JackCompiler.sh projects/09/Test
Compiling /Users/adamzerner/code/nand2tetris/projects/09/Test
In Main.jack (line 6): In subroutine main: Expected - or ~ or ( in term
code/nand2tetris »
错误是什么意思?