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

Re: how should %^H work with lexical pramas

Thread Previous | Thread Next
Rafael Garcia-Suarez
March 29, 2006 07:38
Re: how should %^H work with lexical pramas
Message ID:
Nicholas Clark wrote:
> Logically then if feels like compile time state should be stored in struct
> cop:
> But then that's going to make it tricky to make it read write, as my
> understanding was that the optree is shared between threads, so any thread
> writing to the field will be scribbling on the state read by all the rest.

And is going to be thread-unsafe.

> > Yes, currently hints aren't propagated in eval("") (except a few ones,
> > ie. some strictures and all warnings).
> Where do the other hints bits currently get lost?
> I see this in pp_entereval:
>     SAVEHINTS();
>     PL_hints = PL_op->op_targ;
>     if (saved_hh)
> 	GvHV(PL_hintgv) = saved_hh;
> and as op_targ is at least 32 bits, I was assuming that it had space for all.
> So the loss can't be at this point.

You're right, eval("") doesn't loose strictures. It's caller() that does
(since the op_private field of cops only store the lowest 8 bits of

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