Does the new Swift 5.5 init(projectedValue:) functionality not work with synthesized memberwise initializers?

I think that would create a dialect, which is unaligned with Swift's principles. I'd argue for the opposite:

  1. a Swift 5 flag to opt into deprecation mode; and
  2. a Swift 6 deprecation,

This is akin to Concurrency's handling of erroneous code (EDIT) in Swift 5 mode: it is permitted with an option to be warned about it.

To further ease migration, we could also soft-deprecate traditional inits in Swift 5. That is, we wouldn't suggest them in auto-completion, while keeping them valid and warning-free.


I think keeping around both inits is preferable given Swift's source-compatibility constraints.


I'd love to write a pitch for this! When you are ready, or if anyone else is interested, feel free to DM me.

EDIT: Along with a new init for wrapped properties, we could completely overhaul wrapper-related initialization with projection-based wrapped-property initialization.

1 Like