3 ms·
rust has parametric polymorphism, it just calls it generics—and traits correspond to ocaml signatures. These aren't useful juxtapositions.
by riwsky 5y ago
rust has parametric polymorphism, it just calls it generics—and traits correspond to ocaml signatures. These aren't useful juxtapositions.
- LAC-Tech 5y agoI'll take your word that I'm misusing the terms. Key difference - as a user - is in Ocaml I'd write a module with a bunch of functions. In rust I'd write a struct with a bunch of methods. It feels very different even if it solves the same things.