What happened to the "mutable struct" debate?
mark at talios.com
Fri Jan 23 04:16:06 UTC 2015
On 23 Jan 2015, at 16:31, Andrew Purtell wrote:
> Our mantra is “codes like a class, works like an int.”
> Stating the obvious, from a newcomer's perspective, ints are mutable.
Surely it's the *reference* to the int that's mutable, not the int itself.
5 = 0;
10 / 5 -> DivByZero? I think ( and hope ) not.
int v = 5
v = 0
10 / v -> DivByZero.
More information about the valhalla-dev