summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaCoroutine.cpp
diff options
context:
space:
mode:
authorBrian Gesiak <modocache@gmail.com>2019-01-11 01:54:53 +0000
committerBrian Gesiak <modocache@gmail.com>2019-01-11 01:54:53 +0000
commit5488ab4ddd47af2151d79940e805914da56d6562 (patch)
tree8ad5b4aa3f9b7e7f17e5cd49d1d4a0a744185793 /clang/lib/Sema/SemaCoroutine.cpp
parentf8b8b39c60f8d6558a38806c785f824d1b3174c0 (diff)
downloadbcm5719-llvm-5488ab4ddd47af2151d79940e805914da56d6562.tar.gz
bcm5719-llvm-5488ab4ddd47af2151d79940e805914da56d6562.zip
[AST] Remove ASTContext from getThisType (NFC)
Summary: https://reviews.llvm.org/D54862 removed the usages of `ASTContext&` from within the `CXXMethodDecl::getThisType` method. Remove the parameter altogether, as well as all usages of it. This does not result in any functional change because the parameter was unused since https://reviews.llvm.org/D54862. Test Plan: check-clang Reviewers: akyrtzi, mikael Reviewed By: mikael Subscribers: mehdi_amini, dexonsmith, cfe-commits Differential Revision: https://reviews.llvm.org/D56509 llvm-svn: 350914
Diffstat (limited to 'clang/lib/Sema/SemaCoroutine.cpp')
-rw-r--r--clang/lib/Sema/SemaCoroutine.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/clang/lib/Sema/SemaCoroutine.cpp b/clang/lib/Sema/SemaCoroutine.cpp
index a84116c1bcc..181efa6d3dd 100644
--- a/clang/lib/Sema/SemaCoroutine.cpp
+++ b/clang/lib/Sema/SemaCoroutine.cpp
@@ -84,8 +84,7 @@ static QualType lookupPromiseType(Sema &S, const FunctionDecl *FD,
// ref-qualifier or with the & ref-qualifier
// -- "rvalue reference to cv X" for functions declared with the &&
// ref-qualifier
- QualType T =
- MD->getThisType(S.Context)->getAs<PointerType>()->getPointeeType();
+ QualType T = MD->getThisType()->getAs<PointerType>()->getPointeeType();
T = FnType->getRefQualifier() == RQ_RValue
? S.Context.getRValueReferenceType(T)
: S.Context.getLValueReferenceType(T, /*SpelledAsLValue*/ true);
@@ -506,7 +505,7 @@ VarDecl *Sema::buildCoroutinePromise(SourceLocation Loc) {
auto *FD = cast<FunctionDecl>(CurContext);
bool IsThisDependentType = [&] {
if (auto *MD = dyn_cast_or_null<CXXMethodDecl>(FD))
- return MD->isInstance() && MD->getThisType(Context)->isDependentType();
+ return MD->isInstance() && MD->getThisType()->isDependentType();
else
return false;
}();
OpenPOWER on IntegriCloud