File tree Expand file tree Collapse file tree 1 file changed +0
-17
lines changed Expand file tree Collapse file tree 1 file changed +0
-17
lines changed Original file line number Diff line number Diff line change @@ -1325,23 +1325,6 @@ namespace {
1325
1325
wrapperInfo.wrappedValuePlaceholder ->getOriginalWrappedValue ())
1326
1326
return false ;
1327
1327
1328
- // If we have a nonmutating setter on a value type, the call
1329
- // captures all of 'self' and we cannot rewrite an assignment
1330
- // into an initialization.
1331
-
1332
- // Unless this is an assignment to a self parameter inside a
1333
- // constructor, in which case we would like to still emit a
1334
- // assign_by_wrapper because the setter will be deleted by lowering
1335
- // anyway.
1336
- if (!isAssignmentToSelfParamInInit &&
1337
- !VD->isSetterMutating () &&
1338
- VD->getDeclContext ()->getSelfNominalTypeDecl () &&
1339
- VD->isInstanceMember () &&
1340
- !VD->getDeclContext ()->getDeclaredInterfaceType ()
1341
- ->hasReferenceSemantics ()) {
1342
- return false ;
1343
- }
1344
-
1345
1328
// If this property wrapper uses autoclosure in it's initializer,
1346
1329
// the argument types of the setter and initializer shall be
1347
1330
// different, so we don't rewrite an assignment into an
You can’t perform that action at this time.
0 commit comments