Browse thread
Wrapping a C function that takes a variable number of arguments
- Joel Reymont
[
Home
]
[ Index:
by date
|
by threads
]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
[ Message by date: previous | next ] [ Message in thread: previous | next ] [ Thread: previous | next ]
Date: | 2007-09-06 (23:24) |
From: | Joel Reymont <joelr1@g...> |
Subject: | Wrapping a C function that takes a variable number of arguments |
I'm trying to figure out how to wrap Cocoa's NSLog [1]. It's basically just like fprintf in that the signature looks like this void NSLog(NSString *format, ...); There must be an idiomatic way of creating a wrapper for such a function, probably with a bit of dark magic. Would someone please show me how? Thanks, Joel [1] http://www.cocoadev.com/index.pl?NSLog -- http://wagerlabs.com