0

Is it possible to disable warnings for particular piecies of code in xcode? I'm using a library I didn't write myself, and it creates hundreds of warnings. This makes it very unclear to find warnings related to my code. Is it possible to disable when #import-ing the headers and re-enabling warnings immediately after? I remember this was possible in some other IDE, maybe Visual Studio, maybe with some #pragma. Anything similar in xcode? Thanks!

Luca Carlon
  • 9,546
  • 13
  • 59
  • 91

1 Answers1

-1

Open your project in XCode, then right click on your target in the Targets folder. Select "Get Info" form the drop down menu and then scroll down to the section for the compiler warnings (GCC 4.0 Warnings on my box). Here you can disable the checkboxes for the various warnings you have active. Also check the value of "Other Warning Flags". This could include -Wall or -WMost which will enable other warnings. You can remove that and hopefully your warnings will not appear.

Aluminum
  • 2,932
  • 5
  • 35
  • 63
  • 1
    If I'm not misunderstanding, those options are related to the whole project, right? I don't want specific types of warnings to be disabled, I just want any warning related to my libraries to be disabled, as those are not up to me to handle. – Luca Carlon Nov 21 '10 at 22:05