summaryrefslogtreecommitdiffstats
path: root/clang/lib
diff options
context:
space:
mode:
authorBenjamin Kramer <benny.kra@googlemail.com>2011-09-21 06:42:26 +0000
committerBenjamin Kramer <benny.kra@googlemail.com>2011-09-21 06:42:26 +0000
commit5ce7f109cf91bd8237a73a68a487aae578078261 (patch)
treeaae11d141be540205152d1344fca517fe02c61ee /clang/lib
parent9eaefa9786ac20da40966719f9920fb223d89ea8 (diff)
downloadbcm5719-llvm-5ce7f109cf91bd8237a73a68a487aae578078261.tar.gz
bcm5719-llvm-5ce7f109cf91bd8237a73a68a487aae578078261.zip
Fix MSVC9 build by providing a full comparator object to lower_bound.
llvm-svn: 140238
Diffstat (limited to 'clang/lib')
-rw-r--r--clang/lib/Serialization/ASTReader.cpp10
1 files changed, 8 insertions, 2 deletions
diff --git a/clang/lib/Serialization/ASTReader.cpp b/clang/lib/Serialization/ASTReader.cpp
index 6e8d1cb22f5..5f489d40678 100644
--- a/clang/lib/Serialization/ASTReader.cpp
+++ b/clang/lib/Serialization/ASTReader.cpp
@@ -2905,12 +2905,18 @@ struct PPEntityComp {
PPEntityComp(const ASTReader &Reader, Module &M) : Reader(Reader), M(M) { }
- bool operator()(const PPEntityOffset &L, SourceLocation RHS) {
+ bool operator()(const PPEntityOffset &L, const PPEntityOffset &R) const {
+ SourceLocation LHS = getLoc(L);
+ SourceLocation RHS = getLoc(R);
+ return Reader.getSourceManager().isBeforeInTranslationUnit(LHS, RHS);
+ }
+
+ bool operator()(const PPEntityOffset &L, SourceLocation RHS) const {
SourceLocation LHS = getLoc(L);
return Reader.getSourceManager().isBeforeInTranslationUnit(LHS, RHS);
}
- bool operator()(SourceLocation LHS, const PPEntityOffset &R) {
+ bool operator()(SourceLocation LHS, const PPEntityOffset &R) const {
SourceLocation RHS = getLoc(R);
return Reader.getSourceManager().isBeforeInTranslationUnit(LHS, RHS);
}
OpenPOWER on IntegriCloud