Add operator '<=' for comparing SourceLocations.

llvm-svn: 73820
This commit is contained in:
Argyrios Kyrtzidis 2009-06-20 08:08:38 +00:00
parent ce3797527e
commit ef21d5d870
1 changed files with 4 additions and 0 deletions

View File

@ -145,6 +145,10 @@ inline bool operator<(const SourceLocation &LHS, const SourceLocation &RHS) {
return LHS.getRawEncoding() < RHS.getRawEncoding();
}
inline bool operator<=(const SourceLocation &LHS, const SourceLocation &RHS) {
return LHS.getRawEncoding() <= RHS.getRawEncoding();
}
/// SourceRange - a trival tuple used to represent a source range.
class SourceRange {
SourceLocation B;