[erlang-questions] Fwd: Why single-assignment with non-shared state?
Sun Oct 21 15:05:13 CEST 2007
Well as long as the expressions you match on doesn't change during
matching I do not see the problem. There are several prominent
languages such as the ML-family, Scala, or even Lisps which feature
both pattern matching and assignment.
On 20 oktober 2007, at 13.33, Ulf Wiger wrote:
> While single assignment and pattern matching go very well
> together, it's a little bit less obvious how mutable state and
> pattern matching would combine as nicely. Erlang's current
> semantics for binding and matching make it quite straight-
> forward to reason about even very complex programming
> Ulf W
> 2007/10/20, Tobias Gerdin <>:
>> Hi there,
>> I do not understand why the single-assignment restriction exists in
>> Erlang (even though I very much enjoy functional programming) given
>> that processes do not share state. What is the problem with mutable
>> state in a concurrent system when other processes cannot access other
>> processes' state?
>> I was hoping someone could enlighten me on this matter.
>> erlang-questions mailing list
More information about the erlang-questions