On Thursday, March 21, 2002, at 08:54 PM, Bernie Bright wrote:
> David Megginson wrote:
>>
>> OK, first let's make sure that my code is correct ANSI C++ before we
>> beat up on MSVC. Basically, I have this:
>>
>> #include <algorithm>
>> SG_USING_STD(sort);
>>
>> which is equivalent to
>>
>> #include <algorithm>
>> using std::sort;
>>
>> Is this correct? I think it is, but confirmation would be nice.
>>
>
> This is indeed Std C++ and is correct.
>
> The following compiles fine with MSVC6sp3:
>
> #include <algorithm>
> #include <vector>
> int main() {
> std::vector<int> v;
> std::sort( v.begin(), v.end() );
> return 0;
> }
>
> Replacing std::sort() with sort() and adding using std::sort; also
> works.
>
> Cheers,
> Bernie
With the irregularity that I am having problems with "using XXX" I get the
feeling that there is something wrong with a header someplace, or a
#define. Not all modules generate the error, and others (namely the
updates, and only the updates, to JSBSim) blow body parts across the room.
I can change the behavior of JSBSim by rearranging the #includes in some
of the modules, but I cannot get rid of the errors.
Is anyone else building under MSVC 6.0 (or other MSVC compiler)?
Thanks,
Jonathan Polley
_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel