[erlang-questions] Is export always better than complie(export_all)?
Thu Jun 20 18:30:28 CEST 2013
export_all should only be used when debugging
In production you should only explicitly export the functions you need.
By exporting a subset of the functions:
- your programs are easier to understand.
- the compiler could perform better optimisations
- the type checker (dialyzer) can infer better types
On Thu, Jun 20, 2013 at 7:57 AM, 饕餮 <249505968@REDACTED> wrote:
> I'm working in a program as 10,000 line code.
> Most of the time the function are changing.
> Like and some new function or change some old.
> The program is not so big that we have no document to describe our module.
> And all the team member should read all of the code.
> And I usually use compile expert_all because I feel it make the work
> easier to handle
> But one of my teammate said that I must never use export_all.
> It's that necessary to use export() instead of compile(export_all)?
> And what's the reason to use export?
> erlang-questions mailing list
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the erlang-questions