Entirely! The BEAM makes such a fantastic glue engine. ^.^
Yeah I think that is it too. I quite prefer erlang syntax over, say, elixir (ah if erlang had elixir-style macros, entirely doable ^.^). I think most of the fear of erlang's syntax is it is not C-like, at least that was the issue a 1.5 decades ago I'd say. But yeah, I do get that bit of puzzling/annoying bit.
Not a barrier at all, however it does mean the JIT cannot take advantage of static type information to generate better machine code. ^.^;
Lol, true true, they have their specific functions, like
Commas are just a form of scoping, like take this convoluted example between elixir (uses commas) and ocaml (uses spacing):
f a, (b 4, 5), c+1, d
f a, b(4, 5), c+1, d
(* OCaml *)
f a (b 4 5) (c+1) d
You are swapping commas for parenthesis or vice-versa (although ocaml has other scoping constructs, parenthesis is what you'd most likely use in this case). Elixir optimizes for 'heavy' arguments, where the arguments are often more then just a binding and are often more complex expressions. OCaml optimizes for 'light' arguments, where the arguments are often just a binding and where more complex expressions need to be scoped. Elixir requires OCaml-Like scoping in cases where things become ambiguous where OCaml does not have the ambiguity at all as it enforces it. Just different styles in that way.
Likewise, makes refactoring a hell.
Ah perl, the language where you can call something identically in the same place and get back entirely different results, so powerful, but holy frick it is brain draining. ^.^;
But that example would generally be. ^.^
Technically your example in pure OCaml would be like:
DB.save ~use_transaction:true ~logging:"HIGH" record
And of course you can stop at any point to partially apply it, so could do this:
(* somewhere higher *)
let db_trans_save = DB.save ~use_transaction:true ~logging:"HIGH"
(* in functions *)
Traditional OCaml would have the use transaction and logging be optional arguments, can be left off, with the final argument(s) being the main data load.
I'm not sure where the macro's come from though, Ruby does not have macro's (though you can monkeypatch to hell), if not Lisp of course (that is what they are closest to by far, heck even sigils can enable a kind of scoped read-macro's), so I'm not sure what ruby brings to elixir other than the syntax itself, which is about the only part of elixir I really really dislike for a multitude of reasons. Ignoring syntax the big main thing I'd change of Elixir is piping to last instead of first, that'd recover compatibility with the multitude of Erlang libraries, allowing them to be used in-place without needing to remake or create thousands of wrappers as Elixir has done, which makes using Erlang in Elixir significantly less popular than it would have been otherwise.