[erlang-questions] Retrieve all auto-imported functions
Mon Jan 30 18:48:16 CET 2012
I don't know why it does this, it doesn't make sense. Of course import in Erlang doesn't do what many expect, ALL it does is a little name munging so you don't need to write the module name when calling the imported functions. The functions aren't "imported" into the module in any way or become special in any way. It only provides some syntactic sugar and has no semantic meaning at all.
----- Original Message -----
> No answer, just removing a dead-end. Given a simple module(*) I get
> 5> t:module_info(imports).
> Perhaps this is Erlang/OTPs way to remind us to avoid -import()?
> -import(lists, [reverse/1]).
> t() -> reverse([1,2,3]).
> On Sun, 2012-01-29 at 19:40 +0100, José Valim wrote:
> > Is there a way to retrieve all auto-imported functions in parse
> > time
> > and/or runtime?
> > erlang:module_info(exports) also returns non auto-imported
> > functions.
> > Thanks in advance,
> > José Valim
> > www.plataformatec.com.br
> > Founder and Lead Developer
> erlang-questions mailing list
More information about the erlang-questions