More tests and fixes (unary, binary, globals)

This commit is contained in:
dcodeIO
2017-12-02 18:37:59 +01:00
parent ef859937a8
commit b9edfb5185
22 changed files with 2159 additions and 80 deletions

22
tests/compiler/if.ts Normal file
View File

@ -0,0 +1,22 @@
export function ifThenElse(n: i32): bool {
if (n)
return true;
else
return false;
}
export function ifThen(n: i32): bool {
if (n)
return true;
return false;
}
export function ifThenElseBlock(n: i32): bool {
if (n) {
; // nop
return true;
} else {
; // nop
return false;
}
}