develooper Front page | perl.perl5.porters | Postings from July 2013

[perl #117543] protect some magic %main:: symbols from being deleted

Thread Next
Tony Cook via RT
July 17, 2013 05:38
[perl #117543] protect some magic %main:: symbols from being deleted
Message ID:
On Wed Apr 10 04:29:03 2013, nicholas wrote:
> But I guess this comes down to a design decision - what are those
> pointers
> really about. Are they a speedup, where the desired semantic remains
> that
> the interpreter behaves as if it's looking things up in %:: as it
> needs them?
> Or are they a specified part of the implementation, in that the
> interpreter's
> direct pointers are *initially* made available in %::, but if Perl-
> space is
> careless it can loose its access to them?

I'd mostly prefer to protect symbols, but I wonder if that would
prevent interesting uses[1] of the current implementation.

We have three choices I can think of:

1) retain the current implementation - the user can crash perl from 
pure perl, but there might be interesting things the user can do 
with that power.

2) protect any globals connected to PL_* from deletion

3) ensure PL_* are updated when their perl variables are updated.

I can see 2) or 3) having a performance impact if they cover all the
variables we want to protect (if we do it by name.)

I don't really have an opinion either way.


(Looking at this ticket because it has patches.)

[1] none of which I can think of right now

via perlbug:  queue: perl5 status: open

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