On 11/14/15 5:49 PM, Timon Gehr wrote:
It's supposed to guarantee that the given reference is not used to
transitively mutate the object. The casts violate this.

I think that semantics needs to change. Specifically, either we add a @mutable attribute (which means const doesn't apply to fields marked as such and immutable objects cannot be created); or we could just decree that if a const object originates in a mutable object, casts should be well-defined. -- Andrei

Reply via email to