Skip to content

Commit f1051f1

Browse files
authored
Merge pull request #63465 from xedin/issue-63264
[CSSyntacticElement] Correctly determine whether body is a "single ex…
2 parents 44c46c2 + e3ea597 commit f1051f1

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

lib/Sema/CSSyntacticElement.cpp

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2396,7 +2396,10 @@ bool ConstraintSystem::applySolutionToBody(Solution &solution,
23962396
if (!body || application.hadError)
23972397
return true;
23982398

2399-
fn.setTypecheckedBody(cast<BraceStmt>(body), fn.hasSingleExpressionBody());
2399+
fn.setTypecheckedBody(cast<BraceStmt>(body),
2400+
solution.getAppliedBuilderTransform(fn)
2401+
? false
2402+
: fn.hasSingleExpressionBody());
24002403
return false;
24012404
}
24022405

0 commit comments

Comments
 (0)