On Thursday, 6 October 2016 at 01:23:35 UTC, Patric Dexheimer wrote:
Why?

Because you'd be overwriting that immutable member. Structs just put structure around their contents, but it doesn't change their nature. That struct is no different than if you wrote `immutable size_t` as the value - and of course, overwriting that; changing that violates that promise that you won't change it.

You could store pointers to those structs though, and overwrite the pointer.

Reply via email to