3 ms·
It is much more like JavaScript than ocaml and so you get a familiar language but one which benefits from all the cool things that ocaml can do.
by phpnode 10y ago
It is much more like JavaScript than ocaml and so you get a familiar language but one which benefits from all the cool things that ocaml can do.
- k__ 10y agoAnother n00b question: What are "all the cool things that ocaml can do"? I only saw rather simple typing examples, which didn't seem much different from what TypeScript can do. On the other hand I read often that ocaml doesn't have runtime errors, which I certainly get with TypeScript.
- yawaramin 10y agoThis is a good overview I think, although it doesn't get into specifics: https://realworldocaml.org/v1/en/html/prologue.html#why-ocaml https://realworldocaml.org/v1/en/html/prologue.html#why-ocam... Of course the rest of the book is a great read too if you're so inclined.
- eru 10y agoOCaml does have exceptions at runtime (eg if you try to take the maximum of an empty list), but generally your programmes won't have type errors at runtime.