2 ms·
Isn't there a compiler extension for hkt?
by dunefox 6y ago
Isn't there a compiler extension for hkt?
- dan-robertson 6y agoNot for ocaml
- dunefox 6y agoI meant for Haskell, did you mean for Ocaml originally?
- dan-robertson 6y agoIf you look at the comment chain, you see: - I don’t like lazy - ocaml is like Haskell but strict - I want higher kinded types (note this is a feature you can turn on in Haskell but ocaml does not have it[1]. The commenter is implying that ocaml is therefore not a sufficient strict Haskell) - you say that higher kinded types are an option, which is true for Haskell but not for ocaml which is being proposed. [1] there are ways to sort-of do higher kinder types in ocaml but they are not ergonomic and feel a bit hacky to me.
- saityi 6y agoIn case anyone is curious about [1], there is a paper called Lightweight higher-kinded polymorphism -- http://ocamllabs.io/higher/lightweight-higher-kinded-polymorphism.pdf http://ocamllabs.io/higher/lightweight-higher-kinded-polymor... -- that goes into some of the possible encodings.