[erlang-questions] Function to syntax tree

Boris Okner boris.okner@REDACTED
Sun May 2 17:11:33 CEST 2010


Yes, I read beam_lib documentation. I still don't see how can I use it to
get BEAM code for the anonymous function dynamically created during
run-time.

Boris

On Sun, May 2, 2010 at 10:59 AM, Richard Carlsson <
carlsson.richard@REDACTED> wrote:

> Boris Okner wrote:
>
>> Thanks Richard,
>>
>> So the sequence you're suggesting is:
>>
>> Function -> BEAM code -> Erlang source code -> AST?
>>
>> Still,  assuming second step done by Decompiler, 3rd step by erl_scan and
>> erl_parse, how do I get a BEAM code for anonymous function?
>>
>
> Look at the documentation for the beam_lib module in stdlib. Also,
> if the code has been compiled with debug information, it is almost
> trivial to reconstruct the source code (see beam_lib for details).
>
>    /Richard
>


More information about the erlang-questions mailing list