[erlang-questions] Adding file and line information to erl_syntax trees.

Marc Worrell marc@REDACTED
Mon Aug 21 11:57:15 CEST 2017


Hi,

In Zotonic (the Erlang CMS) we are using template_compiler [1] to compile ErlyDTL templates to beam modules.

I would like to include filename and line positions from the original template files in the generated beam code.
This to ease debugging, especially in the case of crashes.

I am a bit at a loss how to best include this information into erl_syntax abstract trees.

Does anybody have an example how to include this information?

Thanks,

Marc

[1] https://github.com/zotonic/template_compiler




More information about the erlang-questions mailing list