Transitive const sucks

Walter Bright newshound1 at digitalmars.com
Wed Sep 12 17:07:24 PDT 2007


Janice Caron wrote:
> I was trying to simplifly. Sigh. The gist of this particular example
> is that have what /starts off/ as perfectly good, non-member-modifying
> code, and all is well. But then you later put in some diagnostics to
> make it write stuff to a file (coz you're debugging) and suddenly it
> no longer compiles and you have keep taking const out of your code all
> over the place until it does.

Or you can cast away const-ness. But you are on your own if you do that.



More information about the Digitalmars-d mailing list