annotate druntime/import/ldc/vararg.di @ 760:6f33b427bfd1

Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
author Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
date Wed, 12 Nov 2008 00:19:18 +0100
parents
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
760
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
1 // D import file generated from 'vararg.d'
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
2 module ldc.Vararg;
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
3 version (LDC)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
4 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
5 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
6 else
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
7 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
8 static assert(false,"This module is only valid for LDC");
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
9 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
10 alias void* va_list;
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
11 template va_start(T)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
12 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
13 void va_start(out va_list ap, ref T parmn)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
14 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
15 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
16 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
17 template va_arg(T)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
18 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
19 T va_arg(ref va_list vp)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
20 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
21 T* arg = cast(T*)vp;
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
22 vp = cast(va_list)(cast(void*)vp + (T.sizeof + size_t.sizeof - 1 & ~(size_t.sizeof - 1)));
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
23 return *arg;
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
24 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
25 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
26 void va_end(va_list ap)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
27 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
28 }
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
29 void va_copy(out va_list dst, va_list src)
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
30 {
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
31 dst = src;
6f33b427bfd1 Seems like hg ignores .di files, so I missed a bunch of stuff. complete druntime should be there now :)
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
diff changeset
32 }