On 5/28/2014 1:49 AM, Russel Winder via Digitalmars-d wrote:
Also, D's approach does not support lazy evaluation, caches of all sorts
etc, that we think are crucial in application software.

Yes, that's so-called "logical const". This has come up several times here, and many have argued strongly to support it.

My view is that logical const is not mechanically checkable, and therefore is a convention. D's const'ness is about guarantees, not conventions.

Of course, D offers an escape from anything. You can do logical constness by using unsafe casts, but the onus is then on you to get it right.

Reply via email to