Take the 2-minute tour ×

I know about the "treat warnings as errors" option in the build settings, but is there any way to set this for specific warnings only, or just for the "may not responds to selector X" ones?

share|improve this question
add comment

2 Answers

Hmm, interesting, was Googling around and found this, if it helps - Selectively disable GCC warnings for only part of a translation unit?

share|improve this answer
Heh not sure how i missed this one, thanks :) Any luck getting something out of it though? –  Zaky German Mar 31 '11 at 9:49
Ah, haven't got around to trying it yet. Was something I was looking for too though, have to see if it works .. –  Tejaswi Yerukalapudi Mar 31 '11 at 14:43
add comment

following the link that Tejaswi supplied, i added this to the file and it generated an error instead of a warning:

#pragma GCC diagnostic error "-Wobjc-method-access"

by the way, getting the warning string for any warning you see in xcode can be done by clicking "reveal in log" for the warning. at the end of the log line for the warning will be the warning string in brackets.

share|improve this answer
add comment

Your Answer


