[PATCH] D52524: Add -Wpoison-system-directories warning

Denis Nikitin via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Thu Sep 12 08:20:03 PDT 2019


denik marked 2 inline comments as done.
denik added inline comments.


================
Comment at: clang/lib/Frontend/InitHeaderSearch.cpp:141-143
+  if (HasSysroot) {
+    if (MappedPathStr.startswith("/usr/include") ||
+        MappedPathStr.startswith("/usr/local/include")) {
----------------
aaron.ballman wrote:
> These should be combined into a single if statement:
> ```
> if (HasSysroot && (MappedPathStr.startswith(...) || MappedPathStr.startswith(...))) {
> ```
Done.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D52524/new/

https://reviews.llvm.org/D52524





More information about the cfe-commits mailing list