source: src/tests/expression.c@ d88f256a

ADT aaron-thesis arm-eh ast-experimental cleanup-dtors deferred_resn demangler enum forall-pointer-decay jacob/cs343-translation jenkins-sandbox new-ast new-ast-unique-expr new-env no_list persistent-indexer pthread-emulation qualifiedEnum resolv-new with_gc
Last change on this file since d88f256a was e757af2, checked in by Thierry Delisle <tdelisle@…>, 9 years ago

renamed all tests to lower-case leading character

  • Property mode set to 100644
File size: 476 bytes
Line 
1int main() {
2 struct s { int i; } x, *p = &x;
3 int i = 3;
4
5 // operators
6
7 ! i;
8 ~i;
9 +i;
10 -i;
11 *p;
12 ++p;
13 --p;
14 p++;
15 p--;
16
17 i+i;
18 i-i;
19 i*i;
20
21 i/i;
22 i%i;
23 i^i;
24 i&i;
25 i|i;
26 i<i;
27 i>i;
28 i=i;
29
30 i==i;
31 i!=i;
32 i<<i;
33 i>>i;
34 i<=i;
35 i>=i;
36 i&&i;
37 i||i;
38 p->i;
39 i*=i;
40 i/=i;
41 i%=i;
42 i+=i;
43 i-=i;
44 i&=i;
45 i|=i;
46 i^=i;
47 i<<=i;
48 i>>=i;
49
50 i?i:i;
51} // main
Note: See TracBrowser for help on using the repository browser.