Hi, as far as I know there is no satisfying solution to your problem. With gcc (and probably clang), you can include third-party stuff via "system includes" which is exactly what you are looking for, but there is no such thing for MSVC to my knowledge. Disabling those warnings through compiler flags will also suppress warnings from within your code... welcome to the pragma push and pop hell.
I would really like to hear from you guys that I'm wrong and there IS a solution. :-) Best, Stefan ________________________________________ Von: Ingmar Wegner [[email protected]] Gesendet: Freitag, 5. Dezember 2014 12:34 An: Mitk Users Betreff: [mitk-users] Suppress compiler warnings from third party toolkits Hi, I have tons of compiler warnings in my VC 2013 project that uses MITK to implement a similar Workbench. I am enabling some special warnings and I want to see the warnings from within my code, but I want to suppress the warnings that come from ITK and such. 1>c:\toolkits\itk\4.5.1\include\itk-4.5\itkNumericTraits.h(282): warning C4310: cast truncates constant value (C:\apps\MyMITKApp\Modules\MyModule\MySpecialModule.cpp) With hundreds of those warnings I don't see my warnings any longer. I have begun to add code as such #pragma warning(push) #pragma warning(disable : 4310 4996) #include <MITK / ITK / VTK> #pragma warning(pop) but this is really tedious! As I guess everybody using those toolkits share the same problem I thought about asking how you guys are getting along with this! A search within the typical userlists and such didn't lead me to a solution. Maybe writing a macro with the filename to be included as argument and then disabling and enabling the warnings toolkit specific? Have a nice weekend, Ingmar ------------------------------------------------------------------------------ Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server from Actuate! Instantly Supercharge Your Business Reports and Dashboards with Interactivity, Sharing, Native Excel Exports, App Integration & more Get technology previously reserved for billion-dollar corporations, FREE http://pubads.g.doubleclick.net/gampad/clk?id=164703151&iu=/4140/ostg.clktrk _______________________________________________ mitk-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/mitk-users
