4 ms·
Can someone familiar with both Rust and F# (or OCaml) type systems write few words about the expressiveness aspect of the language? What would I miss in Rust i
by insulanian 8y ago
Can someone familiar with both Rust and F# (or OCaml) type systems write few words about the expressiveness aspect of the language?
What would I miss in Rust if coming from the F# background?
- steveklabnik 8y agoFun fact: Rust was originally implemented in OCaml, and takes a lot of inspiration from it. Rust was originally described to me by someone as "C meets OCaml." The biggest thing missing in Rust that are in both are higher kinded types. The biggest thing missing from OCaml is parameterized modules.
- insulanian 8y agoF# doesn't actually have HKTs either, unfortunately.
- steveklabnik 8y agoI thought it did, my mistake!
- mamcx 8y agoIn the surface you can say yes or no (only looking at types and such). But summing all the features, F# is far more immediately productive. I take rust after 2 years on F# (that I continue to use). I have like 2 months of Rust now. I still struggle to solve things that are "no-brainers" in F# or swift (mainly, because Rust is VERY strict about know statically all about the code, and VERY hard to build generic, dynamic code). So, it will look less expresive, IMHO. I still ramping-up and start to get more a more of the rust style of programming, so the pain is reduce. With the additions for rust in the near future it will reduce it more, I hope.