summaryrefslogtreecommitdiffstats
path: root/clang/lib/Basic/SourceManager.cpp
diff options
context:
space:
mode:
authorCedric Venet <cedric.venet@laposte.net>2009-02-14 16:15:20 +0000
committerCedric Venet <cedric.venet@laposte.net>2009-02-14 16:15:20 +0000
commitd3c80de95fd19d2da248d6bd9e2aef5a560ecd23 (patch)
treeafe4c6c034bb680a848c92ba0f059bc33f5d1b13 /clang/lib/Basic/SourceManager.cpp
parentb8aa2ea72ab83427d593ff6da1d2df3613052a79 (diff)
downloadbcm5719-llvm-d3c80de95fd19d2da248d6bd9e2aef5a560ecd23.tar.gz
bcm5719-llvm-d3c80de95fd19d2da248d6bd9e2aef5a560ecd23.zip
Fix the build on win32.
llvm-svn: 64556
Diffstat (limited to 'clang/lib/Basic/SourceManager.cpp')
-rw-r--r--clang/lib/Basic/SourceManager.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/clang/lib/Basic/SourceManager.cpp b/clang/lib/Basic/SourceManager.cpp
index cc75b87c467..e023a91f2f1 100644
--- a/clang/lib/Basic/SourceManager.cpp
+++ b/clang/lib/Basic/SourceManager.cpp
@@ -94,6 +94,12 @@ struct LineEntry {
}
};
+// needed for FindNearestLineEntry (upper_bound of LineEntry)
+inline bool operator<(const LineEntry &lhs, const LineEntry &rhs) {
+ // FIXME: should check the other field?
+ return lhs.FileOffset < rhs.FileOffset;
+}
+
inline bool operator<(const LineEntry &E, unsigned Offset) {
return E.FileOffset < Offset;
}
OpenPOWER on IntegriCloud