File tree Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Expand file tree Collapse file tree 2 files changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -7059,6 +7059,7 @@ bool ExtraneousCallFailure::diagnoseAsError() {
7059
7059
}
7060
7060
}
7061
7061
7062
+ anchor.dump ();
7062
7063
auto diagnostic =
7063
7064
emitDiagnostic (diag::cannot_call_non_function_value, getType (anchor));
7064
7065
removeParensFixIt (diagnostic);
Original file line number Diff line number Diff line change @@ -1378,7 +1378,8 @@ namespace {
1378
1378
// references to PackExpansionExpr.
1379
1379
if (auto *postfixExpr = dyn_cast<PostfixUnaryExpr>(expr)) {
1380
1380
auto *op = dyn_cast<OverloadedDeclRefExpr>(postfixExpr->getFn ());
1381
- if (op && op->getDecls ()[0 ]->getBaseName ().getIdentifier ().isExpansionOperator ()) {
1381
+ if (op && Ctx.LangOpts .hasFeature (Feature::VariadicGenerics) &&
1382
+ op->getDecls ()[0 ]->getBaseName ().getIdentifier ().isExpansionOperator ()) {
1382
1383
auto *operand = postfixExpr->getOperand ();
1383
1384
if (auto *expansion = getPackExpansion (DC, operand, op->getLoc ())) {
1384
1385
return Action::Continue (expansion);
You can’t perform that action at this time.
0 commit comments