| Line | |
|---|
| 1 | /* $Id: kKLstdarg.h,v 1.2 2002-01-09 03:21:58 bird Exp $
|
|---|
| 2 | *
|
|---|
| 3 | * Stdarg stuff, with additions to get around some SS != DS trouble.
|
|---|
| 4 | *
|
|---|
| 5 | * Copyright (c) 2001 knut st. osmundsen (kosmunds@csc.com)
|
|---|
| 6 | *
|
|---|
| 7 | * Project Odin Software License can be found in LICENSE.TXT
|
|---|
| 8 | *
|
|---|
| 9 | */
|
|---|
| 10 |
|
|---|
| 11 | #ifndef _kKLstdarg_h_
|
|---|
| 12 | #define _kKLstdarg_h_
|
|---|
| 13 |
|
|---|
| 14 | #include <stdarg.h>
|
|---|
| 15 |
|
|---|
| 16 | /*
|
|---|
| 17 | * va_start have to be redeclared. Compiler don't accept SSToDS() as va_start argument.
|
|---|
| 18 | */
|
|---|
| 19 | #undef va_start
|
|---|
| 20 | #define va_start(ap, last) ap = ((va_list)SSToDS(&last)) + __nextword(last)
|
|---|
| 21 |
|
|---|
| 22 | /*
|
|---|
| 23 | * In order to get rid of the stupid warnings..
|
|---|
| 24 | */
|
|---|
| 25 | #undef va_arg
|
|---|
| 26 | #define va_arg(ap, type) ((type *)(void *)((ap += (int) __nextword(type)) - __nextword(type)))[0]
|
|---|
| 27 |
|
|---|
| 28 |
|
|---|
| 29 | #endif
|
|---|
Note:
See
TracBrowser
for help on using the repository browser.