I'll give this some further thought/discussion later, but this is enough
to unbreak the buildbots at least.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@227034
91177308-0d34-0410-b5e6-
96231b3b80d8
/// of the right bracket.
SourceLocation getOperatorLoc() const { return getRParenLoc(); }
- SourceLocation getExprLoc() const LLVM_READONLY { return getOperatorLoc(); }
+ SourceLocation getExprLoc() const LLVM_READONLY {
+ return (Operator < OO_Plus || Operator >= OO_Arrow ||
+ Operator == OO_PlusPlus || Operator == OO_MinusMinus)
+ ? getLocStart()
+ : getOperatorLoc();
+ }
SourceLocation getLocStart() const LLVM_READONLY { return Range.getBegin(); }
SourceLocation getLocEnd() const LLVM_READONLY { return Range.getEnd(); }