On Friday 16 June 2006 08:29, Klaas-Jan Stol wrote: > Wouldn't it be an idea to have a property 'is_read_only' or something > like that? Then, when attempting to do a write action on a r/o PMC, an > exception is thrown. It would seem to me that this is a typical case for > using a property. > > The disadvantage of course of this approach is that for every > write-operation, this check would have to be done, although this is done > in fast C code, it *is* yet another check to be done.
If I understand this correctly, it's heading in the direction of how Perl 5 works. Swapping the vtable pointer seems, to me, to be both cleaner and probably faster. -- c