[erlang-questions] Compiler to warn on used underscore-variables
Wed Jan 6 16:48:56 CET 2010
----- Original Message ----
> From: Zoltan Lajos Kis <>
> I understand that they are ordinary variables. But I am certain that all
> the _Var variables I have seen so far were named so in order to indicate
> that they are intentionally unused, and not because of some strange naming
> I also understand that many compiler warnings (unused variable, wrong no.
> of args in format call, etc.) are output because there is a clear sign of
> a (semantic) mistake and not because of the source code being invalid.
> So I believe that the current behavior of not warning about a most
> probable mistake with _Var variables is the counter-intuitive one.
> Anyway, such a change would only have a negative effect on those who
> purposefully use such variable names for "ordinary variables". Would not
> affect those who only use the anonymous variable, and would help those
> using these variables as I described.
I like this idea, it catches mistakes and the check can presumably be disabled with a flag in the usual manner.
More information about the erlang-questions