Why is creating an Array inside an Array extension inferring the Element of the extension rather then the init?

Here’s a thread on the topic from 2019: Using the bare name of a generic type within itself

The general opinion seems to be, “We originally thought it was a good idea, but it turned out not to be and we’d like to remove it.”

I don’t know if addressing this issue made it onto the list for Swift 6, but personally I hope so.

7 Likes