Live data from Hacker News

Clojerl – Clojure for the Erlang VM

github.com

41–50 of 105 posts

Re: Clojerl – Clojure for the Erlang VM

#41
post #3

Why would I use this over elixir?

From the readme of the project:

> Clojure is a Lisp and as such comes with all the goodies Lisps provide. Apart from these Clojure also introduces powerful abstractions such as protocols, multimethods and seqs, to name a few. [...] It is fair to say that combining the power of the Erlang VM with the expressiveness of Clojure could provide an interesting, useful result to make the lives of many programmers simpler and make the world a happier place.

Also, at this point Clojure is becoming a kind of nice foundational language with multi-host targets. So if you know Clojure, you can now leverage the JVM, various JS runtimes, the CLR, now also the BEAM, etc. So there's that too. So basically, to someone already knowing Clojure it's a nice way to have access to more platforms.

Re: Clojerl – Clojure for the Erlang VM

#42

Earlier quoted context omitted.

Just use Erlang with Dialyzer. It's not quite as nice as a lanugage with types built-in, but if you're strict about using it, it does work. I won't code without it.

I have burned more time than I care to admit trying to decipher dialyzer output shenanigans. I love dialyzer when my code doesn't generate any errors, and the rest of the time I kind of want to cry.

Yeah, it would be really nice if the function has no local return errors could be more specific.

Re: Clojerl – Clojure for the Erlang VM

#44

Interesting. I'd really like to see Pytherl. Use the easy-to-learn Python syntax, as best as possible, but on the BEAM. I think that would be even better than Elixir for getting people on board.

I doubt this is quite what you are looking for, but https://github.com/fazibear/export provides simple Elixir/Python interop.

Re: Clojerl – Clojure for the Erlang VM

#47
post #3

Why would I use this over elixir?

Another reason might be the "cultural" aspects of Clojure, and their impacts on its ecosystem - in particular simplicity and stability are paramount, whereas the Elixir ecosystem seems to put more emphasis on immediate ease of use and elegance à la Ruby, at the cost of doing some "magical" designs which you tend to not see in the Clojure ecosystem.

Re: Clojerl – Clojure for the Erlang VM

#48
post #6
post #4

Earlier quoted context omitted.

I don’t ...

The JVM is a kitchen sink environment. The BEAM is very opinionated. I would expect the VM built from the ground up to support a specific programming model to be superior at doing just that.

BEAM is a wonderful VM, but calling it "optimized" for anything is problematic. It has focused on certain use cases, but it's seen less than 1% of the investment in the JDK, so I guess it's better to call it "specialized". While it works well enough for many things, its performance is like the JVM limping on both legs after a terrible car accident and a bad case of pneumonia while trying to walk on an icy road. You are correct, though, that it probably performs better than a general-purpose platform with a similar level of investment.

Re: Clojerl – Clojure for the Erlang VM

#50

Earlier quoted context omitted.

Putting an Erlang-like language on the JVM would really lose all the advantages of Erlang, wouldn't it. The syntax, while very useful, isn't the real strength of the language. It's the BEAM.

It looks like this is actually running the real Erlang/OTP, just with some amount of performance penalty from not being on the BEAM. This could be fantastic for fans of BEAM languages who now have a low-profile way to introduce, say, an Elixir proof of concept into a JVM-dominated infrastructure.

Would it really matter though, whether the underlying VM is JVM or BEAM, if people don't want to code in Erlang or Elixir?

I don't think introducing the BEAM is the hard part, I think it's all about the language barrier.

Post reply on HN