Re: Injecting structure to ZEND_NEW

From: Date: Tue, 29 Sep 2015 15:57:49 +0000
Subject: Re: Injecting structure to ZEND_NEW
References: 1  Groups: php.internals 
Request: Send a blank email to internals+get-88556@lists.php.net to get a copy of this message
I think you are looking for opcode handlers, what you want to do is implement a ZEND_NEW handler ... For reference, xdebug and uopz overload handlers, as well as many other extensions ... Cheers Joe On Tue, Sep 29, 2015 at 3:47 PM, Dominic Grostate < codekestrel@googlemail.com> wrote: > I'm trying to pass a new structure into the ZEND_NEW handler which will be > used to change the behaviour of zend_fetch_class_by_name. > > The issue I'm having though is the operands won't support the new type > unless I compile it to zval, but I can't use zend_execute_data to reference > that in a pre-handler since that appears to deal exclusively with function > calls. > > op2 is taken on ZEND_NEW for the ctor skip, which is why I can't pass a new > zval directly to it. Is there another means I can pass the structure in? > > Dominic >

« previous php.internals (#88556) next »