2008/11/7 Robert Osfield <[EMAIL PROTECTED]> > Hi Peter, > > On Fri, Nov 7, 2008 at 12:11 PM, Peter Wraae Marino <[EMAIL PROTECTED]> > wrote: > > there is no push/pop for the warning in the header file which will make > > these warnings disabled in my own code too. I would like to catch this > > warnings in my own code and I shouldn't be forced to enabling them. > > > > the only reason I see for having them grouped here in the header is > > a convience method so osg doesn't have to disable them all places > > that gives these warnings? is this correct? or is there a better reason? > > The warnings that are disabled are ones that were deemed to be not > useful and a hindrance to spotting actual useful warnings. The > placement in the header is to avoid all OSG code have it's own > localise pragma - all of which are platform specific. With the OSG I > try to keep platform specific hacks self contained rather than > distributed out across all code. > > If you really must have the warnings that perhaps one could add a > CMake variable for configuring whether to disable these warnings or > not. This would need to be a VS specific variable. > > Robert. > _______________________________________________ > osg-users mailing list > firstname.lastname@example.org > http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org >
I agree with Peter, arbitrarily turning off peoples warnings isn't good practice. Of course it's the sort of thing people can waste hours arguing about, but some of the those warnings are useful if not important: eg 4996 // 'x': was declared deprecated If somebody is going to make the effort of deprecating stuff, people should know about it. Still there's an easy solution, include the osg headers in your precompiled header and surround them with push/pop... Saves mucking around with osgs config. -- The truth is out there. Usually in header files.
_______________________________________________ osg-users mailing list email@example.com http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org