Create a new expression class, CXXThisExpr, to handle the C++ 'this' primary expression. Remove CXXThis from PredefinedExpr
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@58695 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Sema/SemaExprCXX.cpp b/lib/Sema/SemaExprCXX.cpp
index fde2852..d012473 100644
--- a/lib/Sema/SemaExprCXX.cpp
+++ b/lib/Sema/SemaExprCXX.cpp
@@ -708,8 +708,7 @@
if (CXXMethodDecl *MD = dyn_cast<CXXMethodDecl>(CurContext))
if (MD->isInstance())
- return new PredefinedExpr(ThisLoc, MD->getThisType(Context),
- PredefinedExpr::CXXThis);
+ return new CXXThisExpr(ThisLoc, MD->getThisType(Context));
return Diag(ThisLoc, diag::err_invalid_this_use);
}