Hacker News new | ask | show | jobs
by x5n1 3725 days ago
Is Swift actually a good language, what's good about it? From a general perspective. Been using Go, and love it. Many innovative changes to basically be a C for our century. What's Swift, what have its designers learned from the past to make a better language?
1 comments

Swift includes a lot of high-level features and modern best practices. Off the top of my head, nice stuff that Swift has that Go does not include generics, value-type collections, Optional instead of implicit nil, algebraic data types through enums, let bindings for immutable values, pattern matching, Unicode support at the grapheme cluster level, a REPL, tuples, try/catch error handling, and functional constructs like map/filter/flatMap.