Made parser able to report multiple errors per call, using new Voodoo::Parser::Multip...
[voodoo-lang.git] / test / bitwise.voo
blobd476ae80445c9957b325fab548d37ae2f0f954a7
1 #### Test bitwise operators
3 section data
4 format:
5 string "%08x\n\x00"
7 section functions
8 import printf
9 export main
11 main:
12 function argc argv
13     let oddbits 1431655765
14     let evenbits 2863311530
16     let x not 0
17     call printf format x
18     set x xor x 1431655765
19     call printf format x
20     set x xor x evenbits
21     call printf format x
23     let y or x oddbits
24     call printf format y
25     set y or y 2863311530
26     call printf format y
27   
28     set x and y 2863311530
29     call printf format x
30     set x and -1 1431655765
31     call printf format x
33     return 0
34 end function