[erlang-questions] Why does this compile without warnings/errors?

Yves S. Garret yoursurrogategod@REDACTED
Tue Jul 9 21:02:14 CEST 2013

I'm looking at this code:

loop(ExoSelf_PId) ->
    {ExoSelf_PId, {Id, Cx_PId, ActuatorName, Fanin_PIds}} ->
      loop(Id, Cx_PId, ActuatorName, {Fanin_PIds, Fanin_PIds}, [])

Now, what I'm not quite 'getting' is why the compiler is not complaining
ExoSelf_PId.  First of all, it's not used anywhere.  Second of all, if it's
used, it's
used to bind (to an already bound) variable and that's the message that's
to this process.  If I were to pass in Foo and then do Foo = 5, the
compiler would
tell me that that is impossible, so what is different in this case?
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20130709/01048aec/attachment.htm>

More information about the erlang-questions mailing list