R13B02-1: a patch for omitting a warning on {foo, bar}:fun(args) calls
Yurii Rashkovskii
yrashk@REDACTED
Mon Oct 19 13:33:06 CEST 2009
Hi,
Currently erlc will spit a warning on this kind of constructs:
{db, "localhost"}:connect()
as opposed to
DB = {db, "localhost"},
DB:connect()
The warning will look like:
Warning: invalid module and/or function name; this call will always fail
which is misleading, because this call will not fail (provided modules
are in place and such)
Here is a proposed solution to the problem:
http://github.com/yrashk/erlang/commit/cda6f1727965e6794aa088a200bf6c37c4586958
I am not sure it is perfect (hey, I am not an erlang compiler hacker,
as of yet), but it proved to work quite well for me.
Any chance it can make it to the mainstream in some way?
Thanks,
Yurii.
More information about the erlang-patches
mailing list