Re: How to use VARIANT Structure of C on MAC OSX and XCODE 2.2...............
Re: How to use VARIANT Structure of C on MAC OSX and XCODE 2.2...............
- Subject: Re: How to use VARIANT Structure of C on MAC OSX and XCODE 2.2...............
- From: Boyd Waters <email@hidden>
- Date: Mon, 8 May 2006 15:37:40 -0600
On May 8, 2006, at 3:04 AM, Jonas Maebe wrote:
VARIANT V;
V.vt = VAR_INT;
It gives error as VAR_INT is not declared and vt is of non type
void *.
Okay, you're hosed. This is not a feature of the language.
Indeed, it's a feature of some standard Windows library. It's
possible to implement support for it in any language (also on non-
Windows platforms), but that's quite a bit of work. I don't know of
a pure C implementation.
Sorry, I can't recall if you need interoperability with Microsoft
implementations.
Mozilla XPCOM might be an example implementation of this in C++ that
works well with GCC.
http://www.xulplanet.com/references/xpcomref/ifaces/nsIVariant.html
Mozilla basically took the base Microsoft COM architecture and wrote
a C++ implementation, which they later open-sourced.
You can write a VARIANT implementation that is very inefficient, and
I suppose you can write a better one if you pay attention to data-
alignment issues. So it might be worthwhile to examine (or re-use)
something like XPCOM if you must.
- boyd
Boyd Waters
Socorro, New Mexico
Attachment:
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Darwin-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden