-->

How to disable new Xcode 4.6 warning for whole pro

2019-06-26 11:08发布

问题:

I know how to fix it by inserting whitespace before : , but I have it know in bunch of files after upgrade and this is not important problem for me. I am searching for it in build settings but none seems to address this.

Thank You.

回答1:

So I found this for single file :

#pragma clang diagnostic ignored "-Wmissing-selector-name”

Name I got from here: https://github.com/eerolanguage/clang-trunk/blob/master/test/SemaObjC/warning-missing-selector-name.m

So I put it in precompiled header “Project.pch" and it works for my whole project, I am interested in nicer solution if possible, as user defined build setting for example. I tried it, but not found syntax that worked.