Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Bug fix in saving template containing custom_tags_modules feature
* Bug fix: when compiling templates with custom tags with a given custom_tags_modules option, the arguments are saved as atoms in the AST as opposed to strings. This causes a failure when decompiling the beam and printing its source by erl_prettypr. In order to illustrate the issue compile the template test.dtl containing: {% tr xxx="ABC" %} with options: [ , {doc_root, "src"} , {out_dir, "ebin"} , {compiler_options, [verbose, debug_info, report, return]} , {custom_tags_modules, [custom_tags]} , {force_recompile, true} ]. where custom_tags module is: -module(custom_tags). -export([tr/2]). tr(Vars, Context) -> io:format("Vars: ~p\n Context: ~p\n", [Vars, Context]), []. Observe the return code of erlydtl_compiler:compile/3, and also try to decompile the emitted beam with: [http://erlang.org/pipermail/erlang-questions/2006-January/018813.html]
- Loading branch information