Jon, try to look at the preprocessed files and see what is there when the compiler gets the preprocessed sources from the preprocessor.
I bet there is a macro somewhere ... Greetings On Monday 27 February 2006 14:19, Jon S. Berndt wrote: > > > Here's the offensive code in /usr/local/include/simgear/math/SGMisc.hxx > > > > > > === start === > > > > > > static T min(const T& a, const T& b) > > > > > > === end === > > > > > > The last line, above, is the culprit. As before, the errors are: > > > > > > SGMisc.hxx:28: error: expected unqualified-id before "const" > > > SGMisc.hxx:28: error: expected `)' before "const" > > > SGMisc.hxx:28: error: expected `)' before "const" > > > > > > The rest of the errors (lots of them), likewise involve "min". > > > > > > Jon > > > > It is a handy and typesafe way to program a min or max function. > > You know exactly what type the input arguments are and which the output > > arguments are. > > > > ... > > > > What brakes, but that brakes anyway if you do includes in the > > wrong order, is > > that a prevously defined min/max macro will disturb the > > declaration/implementation of the SGMisc min/max as it would > > disturb that for > > every other min/max declaration/implementation like the std::min/std::max > > functions for example too. > > > > I bet that you defined such a macro and past that include SGMath.h > > > > Mathias > > I know what the min() template definition does - and it looks like a really > good idea. > > However, the code from plib, simgear, and flightgear is all straight from > CVS. I looked at the tests/ subdirectory and examined the headers. I > renamed the JSBSim subdirectory. The test-up code still won't compile, and > gives the same error. Again - this is straight from CVS. Some of the other > code in test-up/ does compile. I'm working under CygWin, but I don't think > this should have any effect. > > Jon > > > > > > ------------------------------------------------------- > This SF.Net email is sponsored by xPML, a groundbreaking scripting language > that extends applications into web and mobile media. Attend the live > webcast and join the prime developer group breaking into this new coding > territory! > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 > _______________________________________________ > Flightgear-devel mailing list > Flightgear-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/flightgear-devel -- Mathias Fröhlich, email: [EMAIL PROTECTED] ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642 _______________________________________________ Flightgear-devel mailing list Flightgear-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/flightgear-devel