ReasonML is adversely affected by it's Ocaml base if anything. StandardML would have been a much better base (they went with Ocaml because it was a lower-effort to implement and Facebook has a lot of Ocaml devs). The first bad part is that Ocaml does not have a language spec. The implementation is the spec. This puts them at the whim of the Ocaml devs with no other options. SML is a standard with several good impleme…
Programming a space invader in OCaml and OpenGL: lessons learned
31–40 of 120 posts
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#32Earlier quoted context omitted.
Which begs the question why not learn the real deal, instead of adding another layer to debug. Programing isn't poetry.
You could say the same thing about Erlang and Elixir. Or Java and Kotlin / Scala. Depending on how well an alternative syntax is requested and adopted by the existing ecosystem surrounding the particular VM, YMMV. Without knowing, I think you get quite different answers in each case.
Focus on platform languages and you always win long term.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#33Earlier quoted context omitted.
Which begs the question why not learn the real deal, instead of adding another layer to debug. Programing isn't poetry.
Because people who know other programming languages, but not ML, might want to read your code, and it's nice if it looks familiar to them.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#34Earlier quoted context omitted.
> ReasonML seems to be just sugar coating That’s exactly what it is, no secret about that, that’s the goal of that project.
Which begs the question why not learn the real deal, instead of adding another layer to debug. Programing isn't poetry.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#35ReasonML is just an alternative syntax for OCaml. Often people use "ReasonML" shorthand for "ReasonML, converted to OCaml, compiled to Javascript with BuckleScript" and "OCaml" for "OCaml compiled natively" but it's perfectly possible (and actually really easy) to use OCaml with BuckleScript and Reason natively. Also note that despite the "O" in the name, OOP in OCaml is rare (for instance, there isn't any in the cod…
What's the state of using Reason natively? Last time I checked all the documentation and examples where towards the reason/js/react ecosystem. Are there any good native code projects written in Reason to look at for reference?
Runs with WebGL and OpenGL.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#36Re: Programming a space invader in OCaml and OpenGL: lessons learned
#37Earlier quoted context omitted.
Because sometimes the layer on top can express ideas more succinctly. A classic example is CoffeeScript's fat arrow syntax. It expressed a pattern in JavaScript we didn't, at the time, have a shorthand for. Example: https://coffeescript.org/#fat-arrow
And now it is dead, leaving behind a pile of code to rewrite in next cool toy.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#38I thought the ocaml stdlib was relatively small though?
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#39Between reasonml and elm which one should I pick?
If you've not used an ML before, start with Elm. Once you feel you have that sussed - it shouldn't take too long - pull up ReasonML and give it a go. Use the Bucklscript-Tea library - the architecture will be familiar from Elm. Then give Reason-React a go. Once that itch has been scratched move on to PureScript for a whole new rabbit hole to fall down.
Re: Programming a space invader in OCaml and OpenGL: lessons learned
#40Earlier quoted context omitted.
And now it is dead, leaving behind a pile of code to rewrite in next cool toy.
In fairness, it's dead because it was shitty and made most things harder, and the things it did improve JS copied. If OCaml fixes its syntax, then we won't have any need for Reason.