Const question

Walter Bright newshound1 at digitalmars.com
Thu Mar 27 23:05:03 PDT 2008


Graham St Jack wrote:
> While I have your attention, what is the plan for expressing that an 
> object is const or immutable and to have a mutable reference to it? 
> Arrays are fine (like "string"), but what is the deal for classes?

There is no plan to have a mutable reference to const class contents. It 
just doesn't work in the type system.



More information about the Digitalmars-d mailing list