mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
Opaques: initialize optionals by-value under new opaque value mode
This commit is contained in:
@@ -3939,7 +3939,7 @@ ManagedValue SILGenFunction::emitInjectEnum(SILLocation loc,
|
||||
}
|
||||
|
||||
// Loadable with payload
|
||||
if (enumTy.isLoadable(SGM.M)) {
|
||||
if (enumTy.isLoadable(SGM.M) || !silConv.useLoweredAddresses()) {
|
||||
if (!payloadMV) {
|
||||
// If the payload was indirect, we already evaluated it and
|
||||
// have a single value. Otherwise, evaluate the payload.
|
||||
|
||||
Reference in New Issue
Block a user