Re: MinGW not so good with exceptions?
* Dave the Funkatron:
Hey all,
I'm using MinGW as part of my toolchain in Eclipse, and I am trying to
figure out why I am getting a compiler error when I include the
<limits> header.
The command that eclipse is running is
g++ -IC:\Dave\School\common\cxx -IC:\Dave\School\common\third party
\packages\glut-3.7.6-bin\include -IC:\Dave\School\common\third party
\packages\pthreads-2005-03-08\Pre-built\include -O0 -g3 -Wall -c -
fmessage-length=0 -ogllib\test_gllib.o ..\gllib\test_gllib.cpp
The error I get is:
In file included from C:/Dave/School/common/cxx/math/math_utils.h:13,
from C:/Dave/School/common/cxx/gfx2d/color.h:9,
from C:/Dave/School/common/cxx/gllib/gl_light.h:
6, from ..\gllib\test_gllib.cpp:8:C:/mingw/bin/../lib/
gcc/mingw32/3.4.5/../../../../include/c++/3.4.5/limits:290: error:
expected `;' before "throw"
C:/mingw/bin/../lib/gcc/mingw32/3.4.5/../../../../include/c++/3.4.5/
limits:292: error: expected `;' before "static"
C:/mingw/bin/../lib/gcc/mingw32/3.4.5/../../../../include/c++/3.4.5/
limits:292:22: macro "max" requires 2 arguments, but only 1 given
There shouldn't be any macro called "max".
If you have defined one yourself, don't.
If you're including some Windows headers, be sure to define NOMINMAX
first to avoid having that macro defined.
Cheers, & hth.,
- Alf
--
A: Because it messes up the order in which people normally read text.
Q: Why is it such a bad thing?
A: Top-posting.
Q: What is the most annoying thing on usenet and in e-mail?