summaryrefslogtreecommitdiffstats
path: root/clang/lib/Frontend
diff options
context:
space:
mode:
authorChris Lattner <sabre@nondot.org>2011-06-16 22:58:10 +0000
committerChris Lattner <sabre@nondot.org>2011-06-16 22:58:10 +0000
commit705c5c8d22db2ad673033707952773af3006741c (patch)
tree597a55301206b5d78b1b99de7b039da75e484bbe /clang/lib/Frontend
parent0c64f4b27e784fb479fd282573511b52390eda77 (diff)
downloadbcm5719-llvm-705c5c8d22db2ad673033707952773af3006741c.tar.gz
bcm5719-llvm-705c5c8d22db2ad673033707952773af3006741c.zip
Fix a regression introduced by r131955 which broke #include_next in subtle situations
because the Angled directories and the System directories were not being uniqued together, breaking #include_next. I'll see about a testcase, but it will be insane. llvm-svn: 133212
Diffstat (limited to 'clang/lib/Frontend')
-rw-r--r--clang/lib/Frontend/InitHeaderSearch.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/Frontend/InitHeaderSearch.cpp b/clang/lib/Frontend/InitHeaderSearch.cpp
index 0b1a2e7a9a6..f94edc65b98 100644
--- a/clang/lib/Frontend/InitHeaderSearch.cpp
+++ b/clang/lib/Frontend/InitHeaderSearch.cpp
@@ -1050,7 +1050,10 @@ void InitHeaderSearch::Realize(const LangOptions &Lang) {
SearchList.push_back(it->second);
}
- RemoveDuplicates(SearchList, NumAngled, Verbose);
+ // Remove duplicates across both the Angled and System directories. GCC does
+ // this and failing to remove duplicates across these two groups breaks
+ // #include_next.
+ RemoveDuplicates(SearchList, NumQuoted, Verbose);
bool DontSearchCurDir = false; // TODO: set to true if -I- is set?
Headers.SetSearchPaths(SearchList, NumQuoted, NumAngled, DontSearchCurDir);
OpenPOWER on IntegriCloud