summaryrefslogtreecommitdiffstats
path: root/clang/lib/Sema/SemaChecking.cpp
diff options
context:
space:
mode:
authorTyker <tyker1@outlook.com>2019-11-17 11:41:55 +0100
committerTyker <tyker1@outlook.com>2019-11-19 18:20:45 +0100
commitb0561b3346e7bf0ae974995ca95b917eebde18e1 (patch)
tree959dcae1398035f974b55bbef71fb1b81417be28 /clang/lib/Sema/SemaChecking.cpp
parentdd471dbe99a7e017357809151df56f2d4c3e7a31 (diff)
downloadbcm5719-llvm-b0561b3346e7bf0ae974995ca95b917eebde18e1.tar.gz
bcm5719-llvm-b0561b3346e7bf0ae974995ca95b917eebde18e1.zip
[NFC] Refactor representation of materialized temporaries
Summary: this patch refactor representation of materialized temporaries to prevent an issue raised by rsmith in https://reviews.llvm.org/D63640#inline-612718 Reviewers: rsmith, martong, shafik Reviewed By: rsmith Subscribers: thakis, sammccall, ilya-biryukov, rnkovacs, arphaman, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D69360
Diffstat (limited to 'clang/lib/Sema/SemaChecking.cpp')
-rw-r--r--clang/lib/Sema/SemaChecking.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/clang/lib/Sema/SemaChecking.cpp b/clang/lib/Sema/SemaChecking.cpp
index 806df77cb27..65e4112d5e5 100644
--- a/clang/lib/Sema/SemaChecking.cpp
+++ b/clang/lib/Sema/SemaChecking.cpp
@@ -9270,7 +9270,7 @@ void Sema::CheckMaxUnsignedZero(const CallExpr *Call,
auto IsLiteralZeroArg = [](const Expr* E) -> bool {
const auto *MTE = dyn_cast<MaterializeTemporaryExpr>(E);
if (!MTE) return false;
- const auto *Num = dyn_cast<IntegerLiteral>(MTE->GetTemporaryExpr());
+ const auto *Num = dyn_cast<IntegerLiteral>(MTE->getSubExpr());
if (!Num) return false;
if (Num->getValue() != 0) return false;
return true;
OpenPOWER on IntegriCloud