Re: Using Erlang libs in Elixir
Dominic Morneau <[email protected]>
| Newsgroups | gmane.comp.lang.erlang.general |
|---|---|
| Message-ID | <CALvPfkoXHaG2OP5OOMx9W-57XGb61aSd5bjxLVVRDLJnD49c+g@mail.gmail.com> |
Telemetry is a good example of an Elixir-friendly Erlang lib, especially the docs: https://github.com/beam-telemetry/telemetry/ Some of the general Elixir library guidelines here also apply in Erlang: https://hexdocs.pm/elixir/library-guidelines.html#content The module name isn't a big deal IMHO, users can just do "alias :erl_lib, as: ErlLib" if it bothers them. Dominic 2021年9月2日(木) 8:04 Serge Aleynikov <[email protected]>: > Is there any guideline for making Erlang projects be more Elixir friendly? > > When developing an Erlang library, it would be nice to have its functions > callable from Elixir not like: > > :erl_lib.some_fun() > > but rather > > ErlLib.some_fun() > > without needing to write a "glue" module compiled into > 'Elixir.ErlLib.beam' that would import all functions from erl_lib and > export them locally? > > Are there more requirements of some metadata (e.g. '__info__'/1) to be > included in the Erlang modules? > > Regards, > > Serge >