We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
return
return nil
1 parent 246f09a commit 71d8a9cCopy full SHA for 71d8a9c
lib/Parse/ParseDecl.cpp
@@ -8732,7 +8732,7 @@ Parser::parseAbstractFunctionBodyImpl(AbstractFunctionDecl *AFD) {
8732
if (F->isFailable() && isa<NilLiteralExpr>(E)) {
8733
// If it's a nil literal, just insert return. This is the only
8734
// legal thing to return.
8735
- auto RS = ReturnStmt::createImplicit(Context, E->getStartLoc(), E);
+ auto RS = ReturnStmt::createImplicit(Context, E);
8736
BS->setLastElement(RS);
8737
AFD->setHasSingleExpressionBody();
8738
AFD->setSingleExpressionBody(E);
0 commit comments