News for hackers. Stuff that matters.
Re:Program FPGAs with Go by zensavona on Tuesday June 13, 2017 @08:48PM (#14549973)
I would argue that Elixir is far closer to being a "JavaScript-like language for concurrent programming" than Go, due to it's dynamic typing and relative freedom it affords in comparison to the others you mentioned (except for Clojure, which is actually quite similar in a lot of ways).

Although it is technically a purely functional language, you can almost mutate variables (in reality it is creating a new immutable variable with the same name, which takes precedence)

  a = 1
  # a == 1
  a = 2
  # a == 2
Concurrency feels very natural:

  # concurrent
  numbers = [1,2,3,4,5]
  doubles =
    |> numbers
    |> Enum.map(fn(n) -> Task.async(fn -> n * 2 end) end)
    |> Enum.map(&Task.await/1)
  # doubles == [2,4,6,8,10]

  # consecutive
  numbers = [1,2,3,4,5]
  doubles = numbers |> Enum.map(fn(n) -> n * 2 end)
  # doubles == [2,4,6,8,10]
Re:Program FPGAs with Go by runeks on Wednesday June 14, 2017 @12:30AM (#14550651)
> Although it is technically a purely functional language [..]

This (purity) stirred my interest, but as far as I can see it's incorrect. This[1] Wikipedia page on pure languages does not list Elixir, and the Elixir Wikipedia page itself does not mention purity at all.

Can anyone clarify?

[1] https://en.wikipedia.org/wiki/List_of_programming_languages_...