compiler-design-eth/javali_tests/from_prev_HW/Expressions.javali
Carlos Galindo 0afc86ceeb
Homework 3
2020-01-15 22:32:25 +01:00

22 lines
No EOL
575 B
Text

/* testing different expressions
compiler should recognize Type error: Return statement of method with void return type should not have arguments
*/
class Main {
void main() {
return;
return true;
return false;
return 0x10;
return 10;
return variable;
return array[index];
return methodAccess();
return object.field;
return object.call();
return op + op2;
return op / asd * asd && a == true;
return this.run();
return this;
return this.field;
}
}