Re:The Unix Philosophy and Elixir as an Alternative to Go
by rubiquity on Tuesday June 23, 2015 @09:27AM
(#9764445)
Take a look at OCaml, or any ML variant language (aside from Rust, which is more C++ than ML in my opinion anyway) for that matter, for a static typed language with a good implementation of generic types.
[ Parent
| on HN ]
Re:The Unix Philosophy and Elixir as an Alternative to Go
by adwn on Tuesday June 23, 2015 @09:47AM
(#9764566)
Would you mind elaborating why you think that Rust doesn't have a good implementation of generic types?
Re:The Unix Philosophy and Elixir as an Alternative to Go
by rubiquity on Tuesday June 23, 2015 @10:17AM
(#9764761)
The signatures can get really unwieldy compared to generics in other languages. As I understand it, the Rust team is working on this.
Re:The Unix Philosophy and Elixir as an Alternative to Go
by pcwalton on Tuesday June 23, 2015 @10:52AM
(#9764979)
I think you're comparing Rust to a language with ad-hoc polymorphism like C++ (where you pay for the somewhat simpler signatures with confusing template instantiation errors), and I'm very glad we didn't follow the C++ route. Rust's generics are very similar to those of Haskell.
The only major generics-related issue that is getting some significant thought is the ability to have the automatically derive the return type on top-level functions, which is not something that is common in other statically typed languages (only C++ and those with whole program type inference, which has its own set of drawbacks).
Re:The Unix Philosophy and Elixir as an Alternative to Go
by dschiptsov on Tuesday June 23, 2015 @12:08PM
(#9765585)
I took the Dan Grossman's PL course, so I appreciate how good Standard ML is.)