Mercurial > projects > ldc
comparison tests/testincludes/std/stdarg.d @ 1595:628433c343b4
Fixed DStress tests nocompile/c/{const_32_B.d,const_32_C.d}.
Updated the runtest script to build libtangobos-partial.a if it hasn't already been built.
Added in signbit() and va_arg!()() to libtangobos-partial.a so more of the phobos dependent DStress tests pass.
author | Robert Clipsham <robert@octarineparrot.com> |
---|---|
date | Sun, 08 Nov 2009 16:16:17 +0000 |
parents | |
children | 42fc0d955a0d |
comparison
equal
deleted
inserted
replaced
1594:9f7151d890ff | 1595:628433c343b4 |
---|---|
1 | |
2 /* | |
3 * Placed in public domain. | |
4 * Written by Hauke Duden and Walter Bright | |
5 */ | |
6 | |
7 /* This is for use with variable argument lists with extern(D) linkage. */ | |
8 | |
9 module std.stdarg; | |
10 | |
11 alias void* va_list; | |
12 | |
13 template va_arg(T) | |
14 { | |
15 T va_arg(inout va_list _argptr) | |
16 { | |
17 T arg = *cast(T*)_argptr; | |
18 _argptr = _argptr + ((T.sizeof + int.sizeof - 1) & ~(int.sizeof - 1)); | |
19 return arg; | |
20 } | |
21 } | |
22 |