annotate run/s/string_postfix_06_C.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 36bedfa079e6
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
736
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
1 // $HeadURL$
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
2 // $Date$
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
3 // $Author$
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
4
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
5 module dstress.run.s.string_postfix_06_C;
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
6
1560
36bedfa079e6 D1 -> D2 : 2/N
thomask
parents: 736
diff changeset
7 int test(string a){
736
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
8 return a.length;
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
9 }
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
10
1560
36bedfa079e6 D1 -> D2 : 2/N
thomask
parents: 736
diff changeset
11 int test(wstring a){
736
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
12 return a.length + 100;
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
13 }
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
14
1560
36bedfa079e6 D1 -> D2 : 2/N
thomask
parents: 736
diff changeset
15 int test(dstring a){
736
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
16 return a.length + 10000;
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
17 }
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
18
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
19 int main(){
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
20 assert(test("a"d "b"d)==10002);
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
21 return 0;
1e6afb94ce6d updated meta data for Torture
thomask
parents:
diff changeset
22 }