Why D const is annoying

Andrei Alexandrescu SeeWebsiteForEmail at erdani.org
Wed May 2 06:57:58 PDT 2012


On 5/2/12 3:10 AM, Mehrdad wrote:
> Whoa, what?
>
> So you're saying
> "X results in UB"
> means
> "Compiler guarantees X"
> ?
>
>
> By that philosophy, C and C++ are orders of magnitude better than D,
> given how many so-called "guarantees" they make about your code...

Casting away const should be statically disallowed in @safe code.

Andrei


More information about the Digitalmars-d mailing list