================ @@ -742,8 +742,12 @@ class CXXBoolLiteralExpr : public Expr { SourceLocation getBeginLoc() const { return getLocation(); } SourceLocation getEndLoc() const { return getLocation(); } - SourceLocation getLocation() const { return CXXBoolLiteralExprBits.Loc; } - void setLocation(SourceLocation L) { CXXBoolLiteralExprBits.Loc = L; } + SourceLocation getLocation() const { + return SourceLocation::getFromRawEncoding(CXXBoolLiteralExprBits.Loc); + } + void setLocation(SourceLocation L) { + CXXBoolLiteralExprBits.Loc = L.getRawEncoding(); ---------------- hokein wrote:
Good point, agree. I don't see a particular reason using the raw encoding here, I think we can use `SourceLocation`, will send out a separate cleanup patch. https://github.com/llvm/llvm-project/pull/146314 _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits