develooper Front page | perl.perl5.porters | Postings from November 2008

Re: Perl_peep (was Re: Perl_linklist)

Thread Previous | Thread Next
From:
Ben Morrow
Date:
November 27, 2008 15:32
Subject:
Re: Perl_peep (was Re: Perl_linklist)
Message ID:
e3n306-d34.ln1@osiris.mauzo.dyndns.org

Quoth nick@ccl4.org (Nicholas Clark):
> On Thu, Nov 27, 2008 at 12:26:51AM +0100, Vincent Pit wrote:
> > 
> > > ... which also means that it should probably not be public, if we
> > > follow the logic that the optree construction should not be public;
> > > Devel::BeginLift is already copying parts of op.c to do its magic.
> > >
> > >   
> > 
> > But isn't the optree construction already kind of public through the
> > pluggable check functions ? They can alter it by replacing ops as they
> > are created.
> 
> Um. Yes. Good point. Not sure.
> Why are these pluggable?

I don't think they were supposed to be, they are just kept in an array
to allow dispatch on op_type. In fact there are a number of ops (PADSV,
for instance) whose constructors never call CHECKOP, which makes hooking
into PL_check a lot less useful than it could be.

Ben


Thread Previous | Thread Next


nntp.perl.org: Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at ask@perl.org | Group listing | About