[erlang-questions] Compiler warnings on impossible constructs?
Arjan Scherpenisse
arjan@REDACTED
Wed Jul 3 13:39:25 CEST 2013
On 03-07-13 13:25, Kostis Sagonas wrote:
> On 07/03/2013 01:16 PM, Arjan Scherpenisse wrote:
>> Hi list,
>>
>> I today fixed a stupid bug in something I wrote last week, namely, an
>> atom-to-atom comparison which should have been a variable-to-atom
>> comparioon:
>>
>> It read: foo =:= bar while it should have read Foo =:= bar.
>>
>> So, my question is, can't Erlang detect this kind of situations on
>> compile time? Obviously, the expression foo =:= bar will never be true,
>> right?
>
> Have you run dialyzer on your code?
Just after I hit "send" i thought the same... I guess I should find a
way to hook dialyzer into flymake.. :)
Arjan
More information about the erlang-questions
mailing list