1

I am using Xcode 4.3 on Mac OS X 10.7.3. Base SDK and Deployment is OS X 10.6.

When I use RegexKitLite, I get lots of compiler warnings: 'Semantic Issue'
Passing 'void *volatile __strong *' to parameter of type 'void *__strong *' discards qualifiers
and
Passing 'void *volatile __strong *' to parameter of type 'void *__strong *volatile' discards qualifiers

Although they appear harmless, it is very annoying since I basically strive for zero warnings. There is no update to RegexKitLite since 2010/04/18, and no discussions about issues with Xcode 4 on sourceforge. With Xcode 3.2, I did not get those warnings.

Is there a way to turn off all warnings only for RegexKitLite?
Or an update to RegexKitLite?

I also attempted to install the framework RegexKit instead of RegexKitLite, but that package has not been updated since 2008/01/29, and instructions for install don't apply to Xcode 4, and there are no sourceforge discussions about issues, and not really elsewhere from what I have seen. Since the RegexKit framework is more powerful than the Lite version, I got interested in it, and at iPhone: RegexKit vs. RegexKit lite - going through an array takes very very long the author of these packages says that RegexKit outperforms the Lite version because it has many optimizations.

Nevertheless, I installed RegexKit framework using hints from How to "add existing frameworks" in Xcode 4? and http://www.thinketg.com/Company/Blogs/11-03-20/Xcode_4_Tips_Adding_frameworks_to_your_project.asp

However, I get 'Semantic Issue' also here, but now these are errors in the header file, and not just warnings:
Pointer to function type 'NSString *' may not be 'restrict' qualified
So it won't even compile!

Is the RegexKit framework not even compatible with Xcode 4?

I have found no info on this, except the link http://www.ohloh.net/p/AGP-Launcher/commits/126607585 which said that he "Changed to RegexKitLite as RegexKit isn't supported in XCode 4".

4

1 回答 1

2

使用叮当声,我将警告静音如下:

在 RegexKitLite.m 的顶部:

#pragma clang diagnostic push
#pragma clang diagnostic ignored "-Wincompatible-pointer-types"

在底部:

#pragma clang diagnostic pop
于 2012-03-22T17:16:16.157 回答