-
Notifications
You must be signed in to change notification settings - Fork 607
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES_ERROR #461
Conversation
Okay, this is getting interesting. I made the changes to straight quotes just a few days ago to help the effort with making OCMock consumable with Swift Package Manager. This change has been suggested in #460, #442, and others. Now you're saying that the headers shouldn't be imported with straight quotes, and with that setting you propose the build actually fails:
What is the way forward here? It felt like having the straight quotes was key to making Swift Package Manager work. |
The latest changes in #460 with the extra files and two directory levels should support both the previous and current import syntaxes. |
interesting … i had thought with this setting, i had built all code and run all tests in all targets to prove that there were no more changes necessary. surprised about your report that it's breaking. i think what i'm saying is that Apple has been saying for a while that bracket-imports are the way to go in headers that will be modular, and that there should be a closure … and when you transition to Xcode12, this is one of the things they recommend turning on. also, in our code-base (separate from OCMock at any rate) we've been using this style in all cases for a while. the solution for Swift Packages has been module.modulemap files. |
back to this change … i think this should be very non-controversial, and whether or not it is included should not be based upon whether or not Swift Package Manager changes are merged or not. Swift Package Manager changes should depend upon this patch. this is an Xcode12 recommendation, and so lots of developers who use OCMock are going to accept that recommendation and then end up with builds that can't build with OCMock due to this. is it possible to move forward with this in this repo? we are moving forward on a branch locally with this change because we have to. |
Confirmed that this change is compatible with the current version of #460 |
===== CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES_ERROR ===== This warning is an Xcode 12 recommendation (technically, the warning is not YES_ERROR, but setting error will ensure that future changes won't regress consumers of OCMock that also set this setting). This setting will help assure modules importing OCMock that it's closure of headers is all modular, and will allow projects also setting this setting to build against OCMock without error. Inspection & testingreveals it is also available already for Xcode11. Changes to .h are the result of - setting CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES_ERROR - building - applying the fix recommended by Xcode
this is holding us up, because any project that wants to accept Xcode 12's upgrade recommendation to do this (and we think it is imperative given our depth of interoperability needs) will fail to build because when tests import OCMock, they will fail to build due to lack of conformance to this in its headers. we're going to go ahead with this patch as is on a local branch. |
Hi, is this going to be merged? |
Just merged it now. The version with straight quotes was never released. |
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES_ERROR
This warning is an Xcode 12 recommendation (technically, the warning
is not
YES_ERROR
, but setting error will ensure that future changeswon't regress consumers of OCMock that also set this setting).
This setting will help assure modules importing OCMock that it's
closure of headers is all modular, and will allow projects also
setting this setting to build against OCMock without error.
Inspection & testingreveals it is also available already for Xcode11.
Changes to .h are the result of
CLANG_WARN_QUOTED_INCLUDE_IN_FRAMEWORK_HEADER = YES_ERROR