From 88920d1a84dc63a3722b1f2b1fb5926c44bd81ab Mon Sep 17 00:00:00 2001 From: Roman Divacky Date: Thu, 23 Aug 2012 13:57:21 +0000 Subject: [PATCH] Mark these const. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@162443 91177308-0d34-0410-b5e6-96231b3b80d8 --- include/clang/AST/Expr.h | 2 +- include/clang/AST/ExprCXX.h | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/clang/AST/Expr.h b/include/clang/AST/Expr.h index dddace82db..0738804ae1 100644 --- a/include/clang/AST/Expr.h +++ b/include/clang/AST/Expr.h @@ -3308,7 +3308,7 @@ public: void setExprs(ASTContext &C, Expr ** Exprs, unsigned NumExprs); - unsigned getShuffleMaskIdx(ASTContext &Ctx, unsigned N) { + unsigned getShuffleMaskIdx(ASTContext &Ctx, unsigned N) const { assert((N < NumExprs - 2) && "Shuffle idx out of range!"); return getExpr(N+2)->EvaluateKnownConstInt(Ctx).getZExtValue(); } diff --git a/include/clang/AST/ExprCXX.h b/include/clang/AST/ExprCXX.h index a2355cadbe..770967255c 100644 --- a/include/clang/AST/ExprCXX.h +++ b/include/clang/AST/ExprCXX.h @@ -1583,7 +1583,7 @@ public: } /// \brief Returns the CXXConstructExpr from this new-expression, or NULL. - const CXXConstructExpr* getConstructExpr() { + const CXXConstructExpr* getConstructExpr() const { return dyn_cast_or_null(getInitializer()); } -- 2.40.0