Add TextWriter, IOException, per-VM module data and pre-load imports; Add console module with Console class
This commit is contained in:
@@ -1,18 +1,19 @@
|
||||
import 'console';
|
||||
class Program {
|
||||
|
||||
public void main() {
|
||||
int $a = 1;
|
||||
switch($a) {
|
||||
case 0:
|
||||
print("very bad\n");
|
||||
Console::Print("very bad\n");
|
||||
break;
|
||||
case 1:
|
||||
print("very good\n");
|
||||
Console::Print("very good\n");
|
||||
case 2:
|
||||
print("good\n");
|
||||
Console::Print("good\n");
|
||||
break;
|
||||
default:
|
||||
print("bad");
|
||||
Console::Print("bad");
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user