On Feb 1, 2008, at 11:49 AM, Aaron W. LaFramboise wrote:
> Brandon Sneed wrote:
>> 5) do something along the lines of...
>> #ifdef _USE_MS_HEADER_ANNOTATIONS
>> #define __out
> My problem with this is that it's not really a solution, because
> _USE_MS_HEADER_ANNOTATIONS becomes equivalent to
> _BREAK_MY_CPP_COMPILERS_HEADERS; switching it on will break the C++
> compiler, so its an option that is impossible to use (in C++). I
> suspect all code that would use __out is C++ code, since most new-
> MSVC-targetted code is for C++, not C.
There are a good number of win32 developers who don't use the STL for
one reason or another, myself included. It is a solution because
people can opt into it, see the ramifications opt back out if they
don't like it. I think the best way do this whole thing is to get gcc
to stop using __out, and hopefully that can be done, but i think
something has to happen in the interim.
> I'm a little confused though. Why do we want __out? There are two
> possible reasons:
> A) To allow w32api developers to use __out in w32api.
> We would want this if we plan for MinGW to support it in the future,
> other w32api users who wanted it.
> B) To allow w32api users to use __out in their code
In my case, i have to share code with VC++ users in addition to making
use of code provided by MS and I'm trying not to rock the boat by
making them conform to me. I wasn't aware of the STL's use of __out
when making the change for the reasons above, but now that its in the
open, some workable solution should happen so that one can have __out
without having to modify everyone else's code to make it work.
> To get some more ideas on this, I've emailed a question about this
> to to
> the libstdc++ mailing list. Perhaps some other platforms have had
> similar problems and can suggest a solution:
Good idea, thanks! I'm looking forward to seeing what they say.