You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Trying to define a property that contains a stored member of the Self type, gives an error even though the member is optional. The diagnostic would make sense if the type was no-optional because that would require an infinite type, but optional members should be allowed?
![](Screen Shot 2020-05-08 at 11.35.42.png)
Is that a bug or intended behavior?
The text was updated successfully, but these errors were encountered:
Optional<T> stores a copy of T inline, so a value type cannot contain an optional of itself. We cannot change this at this point even if we wanted to because of ABI stability.
Attachment: Download
Environment
Swift Development Snapshot 2020-04-29
Additional Detail from JIRA
md5: 9d5c1551c5c2aa5dd379d9eb0144adae
Issue Description:
Trying to define a property that contains a stored member of the Self type, gives an error even though the member is optional. The diagnostic would make sense if the type was no-optional because that would require an infinite type, but optional members should be allowed?
![](Screen Shot 2020-05-08 at 11.35.42.png)
Is that a bug or intended behavior?
The text was updated successfully, but these errors were encountered: