Earlier quoted context omitted.
I've been meaning to get into ClojureScript. Can you elaborate on why it leaves a bad taste in your mouth?
Well, first off, I don't really like Java or the JVM. That in itself is a pretty strong reason to not get into Clojure. Secondly, I don't really like Clojure as a language: It's strongly opinionated, and made some unorthodox (for a lisp) design choices which I dislike. Finally, Clojurescript is really heavyweight, dragging along not only its own runtime, but also the google closure library and compiler, making the en…
Announcing BuckleScript 1.0
51–60 of 78 posts
Re: Announcing BuckleScript 1.0
#52I am one of the authors of BuckleScript, you can try BuckleScript in the browser: http://bloomberg.github.io/bucklescript/js-demo/ Click Examples see how the JS code generated, questions are welcome!
Thanks for this! Really awesome stuff! One question here: how tight the compiler is binded to OCaml semantics? Besides Reason, do you think it's possible to build a frontend for other languages and integrate the backend of BuckleScript to generate beautiful JS as well? Or in other words, what property do you think a language should have so we can generate this level of beautiful JS outputs? BTW: Please understand I'm…
Re: Announcing BuckleScript 1.0
#53Earlier quoted context omitted.
we have an intern this summer create bindings for our internal JS stack. we have some internal stuff running on server side in OCaml which we wish to move to client side. I would say many thanks to my boss and employer's great support
BTW, congratulations on the 1.0 milestone! How did you become so proficient with the OCaml compiler internals? When you started the project did you already know that you can compile to idiomatic js or was that discovered through experimentation?
Re: Announcing BuckleScript 1.0
#54I am one of the authors of BuckleScript, you can try BuckleScript in the browser: http://bloomberg.github.io/bucklescript/js-demo/ Click Examples see how the JS code generated, questions are welcome!
Re: Announcing BuckleScript 1.0
#55Re: Announcing BuckleScript 1.0
#56Earlier quoted context omitted.
yes, we will have this warning when upgraded into OCaml 4.04 Note that optimizing mutual recursive call is a very hard problem it needs VM level support
Mutual tail call optimization requires VM level support in general but can be accomplished within a compiliation unit (module) via inlining.
Re: Announcing BuckleScript 1.0
#57Earlier quoted context omitted.
> Currently it's a syntax on top of OCaml. Does this just mean it compiles to OCaml?
There's a crucial distinction! OCaml's compilation command takes in a `-pp` flag (preprocessor), which accepts a command that takes in a file and outputs an OCaml AST tree. We're basically using that. In that sense, the official OCaml syntax is really just that: another syntax like Reason, but official, and goes back two decades. Because of the clean mapping from one syntax to another, you can toggle between the two…
Re: Announcing BuckleScript 1.0
#58I would love to hear some stories from people using it in production. I'm leaning towards wanting to use a LISP as it's just so elegant... but I feel that getting boggled down in "hard core" functional programming is a bit daunting and limiting.
Re: Announcing BuckleScript 1.0
#59Earlier quoted context omitted.
Very neat. Can BuckleScript compile Core?
as long as it is vanilla OCaml (no c stubs), it should be fine
Did you actually tried to compile core ?
Re: Announcing BuckleScript 1.0
#60I am one of the authors of BuckleScript, you can try BuckleScript in the browser: http://bloomberg.github.io/bucklescript/js-demo/ Click Examples see how the JS code generated, questions are welcome!
Very neat. Can BuckleScript compile Core?
In particular, js_of_ocaml works with both core_kernel and async_kernel.