develooper Front page | perl.perl5.porters | Postings from March 2000

Re: magic

Thread Previous
Ilya Zakharevich
March 28, 2000 16:30
Re: magic
Message ID:
Hugo writes:
> [The suggestions here are not intended for 5.6.0, but I wanted to write
> them down while they were fresh on my soul.]
> I've spent the last couple of days trying to implement a tied variable
> using U magic. After looking at Nick's comments near Tk's use of a
> similar approach (thanks Nick!), I wonder if there is a reason that
> user-definable magics ('U', '~') of the same type should not
> automatically chain.

Agreed.  For many types of magic one should be able to put several
MAGICs of the same type without any conflict, if the API would allow
this.  The current interface does not allow for correct removing of
magic if there are several, so an addition to API may be needed
anyway.  So we may add *two* new APIs: sv_magic_noreplace(), and
sv_unmagic_mg(sv, mg).


Thread Previous Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About