2 ms·
In general, it seems like the authors of Elixir were able to capture more of the cool things about Clojure than LFE. Check out some of the top level functions i
by i_s 10y ago
In general, it seems like the authors of Elixir were able to capture more of the cool things about Clojure than LFE. Check out some of the top level functions in Elixir:
update_in
put_in
get_in
http://elixir-lang.org/docs/stable/elixir/Kernel.html#update_in/3 http://elixir-lang.org/docs/stable/elixir/Kernel.html#update...
These are basically right out of Clojure. It may seem like a small thing, but consistent, well thought out functions like this makes working with immutable data structures much easier.
- rozap 10y agoProtocols are another major concept that Elixir lifted straight from Clojure. IMO one of the nicest ways of doing ad hoc polymorphism.
- junke 10y ago"update", "put" are already available in Erlang[0] and work with nested records[1] if I understand correctly. Likewise, it seems that LFE has map-update for the same use cases[2]. [0] http://erlang.org/doc/man/maps.html http://erlang.org/doc/man/maps.html [1] http://erlang.org/doc/reference_manual/records.html#id86378 http://erlang.org/doc/reference_manual/records.html#id86378 [2] https://github.com/rvirding/lfe/blob/develop/doc/user_guide.txt https://github.com/rvirding/lfe/blob/develop/doc/user_guide....