[Haskell-cafe] off-topic question: why invent new Haskell-like compile-to-js functional languages when we have awesome js_of_ocaml ?

Ömer Sinan Ağacan omeragacan at gmail.com
Mon Nov 11 19:28:44 UTC 2013


Hi all,

Sorry for off-topic question, I'm asking this question here because as
Haskell community we invent lots of new Haskell-like(sometimes a
subset of Haskell like Fay, sometimes different languages with Haskell
syntax and Haskell-like features like Elm and recent language with row
polymorphic records -- I don't remember it's name) languages. What I'm
wondering is that js_of_ocaml project looks like solving all problems
we have. It's supports 100% of OCaml(it translates OCaml bytecode),
and OCaml is arguably better than all languages we invented(awesome
module system, records, strict by default, all OCaml libraries(except
FFI ones) work, like functional data structures, parser generators
etc.)

(I'm assuming we won't have JS backend for GHC anytime soon)

So in short, I don't understand why use Haskell like compile-to-js
languages instead of js_of_ocaml (other than learning purposes -- JS
may be a nice high-level target language to practice writing compilers
etc.)

Please note that I'm not using any compile-to-js languages in my work,
so I may not be able to make a fair comparison, but to me all other
compile-to-js langauges look worse after seeing js_of_ocaml. Of
course, if I had a JS backend for GHC(which would mean compiling
Haskell to JS with all extensions) it would be best solution, but for
now I think js_of_ocaml is superior to all other solutions.

I'm wondering your opinions about this.

Thanks,

---
Ömer Sinan Ağacan
http://osa1.net


More information about the Haskell-Cafe mailing list