[llvm-commits] [llvm] r136485 - /llvm/trunk/utils/TableGen/

David A. Greene greened at obbligato.org
Fri Jul 29 15:50:04 PDT 2011


David Blaikie <dblaikie at gmail.com> writes:

>> Or forgets about auto-generated operations?
>
> That's an upfront issue - the type wasn't actually made immutable.

Well sure, if you want to just define away the problem.

The point is that const-qualification will catch issues like this.

>> Or derives from said type and adds mutating methods?
>
> Hmm - is there a way to make types underivable in C++03? I don't quite
> remember.

Nope, not completely.  C++0x has support for it.

>>  Or writes code that takes a non-const reference and tries to do
>> something to mutate it?
>
> That's the point - the entire interface has no mutating operations.
> It's immutable.

Casting.  I've seen all sorts of nasty things.

In any event, it's moot.  The change is in.

                             -Dave




More information about the llvm-commits mailing list