mirror of
https://github.com/apple/swift.git
synced 2025-12-21 12:14:44 +01:00
The problem was that in the by-address emission, we were calling `getAddressForInPlaceInitialization` twice, triggering the assert. The first time in `emitExprInto` for the normal result case. The second time to obtain the address again when generating the catch block to inject a `.none` into that same address. This patch does a light refactoring to more closely mirror `visitOptionalEvaluationExpr`, which avoids calling the asserting method. fixes rdar://80277465
1.3 KiB
1.3 KiB