Better HN
top
new
best
ask
show
jobs
Log in
Sign up
Better HN
Comment
by
_rend
· 11mo ago · 0 comments
This is Swift, where Type? is syntax sugar for Optional<Type>. Swift's Optional is a standard sum type, with a lot of syntax sugar and compiler niceties to make common cases easier and nicer to work with.
Comments
[–]
_flux
11mo ago
Right, so it's not like a union type Type | Null. Then naturally it works the same way as in the languages I listed.