annotate nocompile/offset_01.d @ 1630:d0efa3ae5522 default tip

run/mini/naked_asm5: New x86_64 ABI passes the arguments in reverse order.
author David Nadlinger <code@klickverbot.at>
date Sat, 23 Apr 2011 22:57:32 +0200
parents f87ba6507260
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
171
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
1 // $HeadURL$
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
2 // $Date$
172
e5bbb877feb9 extended offsetof / offset tests
thomask
parents: 171
diff changeset
3 // $Author$
171
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
4
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
5 // .offset is depricated, use .offsetof
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
6
374
f87ba6507260 added missing meta-data
thomask
parents: 172
diff changeset
7 // __DSTRESS_ELINE__ 19
f87ba6507260 added missing meta-data
thomask
parents: 172
diff changeset
8
171
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
9 module dstress.nocompile.offset_01;
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
10
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
11 struct MyStruct{
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
12 int a;
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
13 int b;
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
14 }
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
15
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
16 int main(){
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
17 MyStruct s;
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
18
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
19 assert(s.a.offset >= 0);
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
20 assert(s.b.offset >= 0);
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
21 assert(s.a.offset != s.b.offset);
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
22
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
23 return 0;
e2ba37f5b797 added .offset deprication tests
thomask
parents:
diff changeset
24 }