Skip to content

Commit a24e7e8

Browse files
authored
Merge pull request #14645 from gottesmm/pr-86cb81fb249a0d3f84cc37ca82cddf17caa5c7fa
2 parents b6db2f0 + b008bfc commit a24e7e8

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/SILGen/SILGenConstructor.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -428,7 +428,7 @@ void SILGenFunction::emitEnumConstructor(EnumElementDecl *element) {
428428
B.createReturn(ReturnLoc, emitEmptyTuple(Loc));
429429
} else {
430430
assert(enumTI.isLoadable() || !silConv.useLoweredAddresses());
431-
SILValue result = mv.forward(*this);
431+
SILValue result = mv.ensurePlusOne(*this, ReturnLoc).forward(*this);
432432
scope.pop();
433433
B.createReturn(ReturnLoc, result);
434434
}

0 commit comments

Comments
 (0)