From 226cbfcd97e400ac1c1afc06d646424136cfe196 Mon Sep 17 00:00:00 2001 From: Douglas Gregor Date: Wed, 15 Sep 2010 01:37:48 +0000 Subject: [PATCH] Fix classification of statement expressions. git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@113917 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/AST/ExprClassification.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/AST/ExprClassification.cpp b/lib/AST/ExprClassification.cpp index b62a00f98e..c9069f8707 100644 --- a/lib/AST/ExprClassification.cpp +++ b/lib/AST/ExprClassification.cpp @@ -264,7 +264,7 @@ static Cl::Kinds ClassifyInternal(ASTContext &Ctx, const Expr *E) { case Expr::StmtExprClass: { const CompoundStmt *S = cast(E)->getSubStmt(); if (const Expr *LastExpr = dyn_cast_or_null(S->body_back())) - return ClassifyInternal(Ctx, LastExpr); + return ClassifyUnnamed(Ctx, LastExpr->getType()); return Cl::CL_PRValue; } -- 2.40.0