compiler

Unnamed Compiled Systems Language Project
git clone http://frotz.net/git/compiler.git
Log | Files | Refs

1020-math-1.src (373B)


      1 
      2 func print(n i32) {
      3 	_hexout_(n);
      4 }
      5 
      6 func test(v2 i32, v5 i32, v31 i32, v128000 i32) {
      7 	// quick check hex and bin consts
      8 	print(0xFFD23137);
      9 	print(0b10001000110100000101000010100001);
     10 	print(v2);
     11 	print(v128000 / 1000);
     12 	print(1 << v5);
     13 	print(~v31);
     14 	print(v31 % 17);
     15 	print(v128000 * v31);
     16 	print(-v128000);
     17 }
     18 
     19 func start() i32 {
     20 	test(2, 5, 31, 128000);
     21 	return 0;
     22 }