[erlang-bugs] `undefined parse transform' parse transforms which call non-existing modules
Klas Johansson
klas.johansson@REDACTED
Tue Feb 17 20:23:20 CET 2015
Hi,
I noticed that a warning has been added to the compiler which says
`undefined parse transform' instead of throwing a (potentially large) parse
tree in the face of the user. Nice! This is the commit:
dba5396 compile: Give a friendler error message if a parse transform cannot
be found
I discovered that is has an unfortunate side-effect:
If an existing parse transform calls a non-existing module, the check will
misinterpret this and print the `undefined parse transform' error.
Tested with compiler-5.0.3 on Erlang/OTP 17.4.
Example parse transform:
-module(x).
-compile(export_all).
parse_transform(_Forms, _Opts) ->
non:existing().
Cheers,
Klas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-bugs/attachments/20150217/f8c13dd8/attachment.htm>
More information about the erlang-bugs
mailing list