On "Why Elixir?"

It’s a fairly new addition to the language, though. There was distillery before(and still is!), but before 1.9 releases weren’t so “blessed” by the language itself. Now reading the docs to run mix release with a :tar step configured is all I need, really.

Considering the latest updates to elixir that focused exactly on configuration and releases, why is it the case now?

I don’t quite get what you mean with that, but for this part:

The core team seems to agree with you.

However, the language is designed to be extremely good at solving a family of problems that made them sacrifice static typing, so it’s a matter of tradeoffs. Considering that, I doubt there is something to be done as it’s a non solved issue and there’s active research going on. Sure, you can interop Gleam with Elixir for the pure, not message related parts, but I feel it as strange as when I try to mix ReasonML with JavaScript, in those cases type-safety is still very hard to achieve. And don’t get me started on TypeScript unsoundness and HORRIBLE web api bindings.

However, while possible for the adventurers, many of those fields are non-goals for the language. This reminds me of the bad usage of the language/libraries that hurts marketing, such as people trying to develop games with LiveView(that I can’t even play because I live at the other end of the world and latency is of at least 300-500ms) and shadowing the usecases that make it unique and tempting.

But Rust is far from being a 1:1 replacement for Elixir, at least not out-of-the box(and I’m not sure there’s something like the BEAM for rust. Emphasis on for as afaik theres a beam implemented in rust).
Elixir and Erlang are all about the guarantees they offer, not only about memory safety or “async capabilities”.

In your gist you mention:

Error handling with tagged tuples is fairly verbose, and we didn’t always have with as a special form, which helped a lot. Similar to my comments above, it’s something that needs intent and attention to handle correctly, because “forgetting to check for nils and errors” is not something that the compiler will call you out for.

But I must say that’s also true for Rust, OCaml, Haskell, Gleam… with the Option/Maybe and Result/Either types. You may also see tagged tuples as ADTs. Sadly, I feel implementing proper abstractions from category theory like those seem odd even in this functional language and such formal ideas are a barrier for people coming from non functional languages. Also point-free style is odd with capture syntax.

It is not my intention to question your reasons, you’ve invested several years on it and you clearly know why you do what you do, moreover I agree with the points I haven’t quoted, but as mentioned in this reply there are many hidden stories behind the opinions we form over time and it’s hard to extract a general gist of where and why are we failing, as it is needed to make case-by-case studies.

This other article from Fred Hebert is a good take on why people come and leave from the beam ecosystem and where value really is.

PS: I rewrote this reply several times and I hope it came out as something productive and not fueling a circular discussion.

5 Likes