File tree Expand file tree Collapse file tree 1 file changed +5
-4
lines changed
Expand file tree Collapse file tree 1 file changed +5
-4
lines changed Original file line number Diff line number Diff line change @@ -4666,10 +4666,11 @@ class CheckEffectsCoverage : public EffectsHandlingWalker<CheckEffectsCoverage>
46664666 void diagnoseRedundantAwait (AwaitExpr *E) const {
46674667 if (auto *SVE = SingleValueStmtExpr::tryDigOutSingleValueStmtExpr (E)) {
46684668 // For an if/switch expression, produce a tailored warning.
4669- Ctx.Diags .diagnose (E->getAwaitLoc (),
4670- diag::effect_marker_on_single_value_stmt,
4671- " await" , SVE->getStmt ()->getKind ())
4672- .highlight (E->getAwaitLoc ());
4669+ Ctx.Diags
4670+ .diagnose (E->getAwaitLoc (), diag::effect_marker_on_single_value_stmt,
4671+ " await" , SVE->getStmt ()->getKind ())
4672+ .highlight (E->getAwaitLoc ())
4673+ .fixItRemove (E->getAwaitLoc ());
46734674 return ;
46744675 }
46754676 Ctx.Diags .diagnose (E->getAwaitLoc (), diag::no_async_in_await)
You can’t perform that action at this time.
0 commit comments