diff options
author | Bruno Cardoso Lopes <bruno.cardoso@gmail.com> | 2018-06-22 18:05:17 +0000 |
---|---|---|
committer | Bruno Cardoso Lopes <bruno.cardoso@gmail.com> | 2018-06-22 18:05:17 +0000 |
commit | 91b3d0660705711eb7ab95139d25b1f8fa9cb7be (patch) | |
tree | aa0c10ee322a4e1d895253135c202c37f58ac6e4 /test/Modules/Inputs/double-quotes/a.hmap.json | |
parent | 14549a3c6a77d7dad9b8079a433008f6a94a3f14 (diff) |
Re-apply: Warning for framework headers using double quote includes
Introduce -Wquoted-include-in-framework-header, which should fire a warning
whenever a quote include appears in a framework header and suggest a fix-it.
For instance, for header A.h added in the tests, this is how the warning looks
like:
./A.framework/Headers/A.h:2:10: warning: double-quoted include "A0.h" in framework header, expected angle-bracketed instead [-Wquoted-include-in-framework-header]
#include "A0.h"
^~~~~~
<A/A0.h>
./A.framework/Headers/A.h:3:10: warning: double-quoted include "B.h" in framework header, expected angle-bracketed instead [-Wquoted-include-in-framework-header]
#include "B.h"
^~~~~
<B.h>
This helps users to prevent frameworks from using local headers when in fact
they should be targetting system level ones.
The warning is off by default.
Differential Revision: https://reviews.llvm.org/D47157
rdar://problem/37077034
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@335375 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Modules/Inputs/double-quotes/a.hmap.json')
-rw-r--r-- | test/Modules/Inputs/double-quotes/a.hmap.json | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Modules/Inputs/double-quotes/a.hmap.json b/test/Modules/Inputs/double-quotes/a.hmap.json new file mode 100644 index 0000000000..bdd383ce41 --- /dev/null +++ b/test/Modules/Inputs/double-quotes/a.hmap.json @@ -0,0 +1,6 @@ +{ + "mappings" : + { + "A.h" : "A/A.h" + } +} |