On Thursday, October 17, 2013 21:17:37 Daniel Davidson wrote: > Strings/slices have sharing. Can the same issue/benefit occur > with primitives? Would you ever have a need for `immutable(int)` > over `const(int)`?
For value types, there's no real difference between immutable and const. Because they're value types, you can't have mutable references to them. The differences between const and immutable only really come into play once you're dealing with reference types, because then you can end up with differently qualified references to the same data. - Jonathan M Davis
