NQP question to add a null value node
Gerd Pokorra
gp at zimt.uni-siegen.de
Fri Mar 4 14:24:42 UTC 2011
Am Freitag, den 04.03.2011, 15:03 +0100 schrieb Moritz Lenz:
> Am 04.03.2011 14:15, schrieb Patrick R. Michaud:
> > On Fri, Mar 04, 2011 at 01:11:43PM +0100, Gerd Pokorra wrote:
> >> How can I add a node with the value null with NQP?
> >> method value:sym<null>($/) {
> >> # ????
> >> }
> >
> > Perhaps...?
> >
> > method value:sym<null>($/) {
> > pir::null();
>
> Should be:
>
> pir::null__p()
>
> Seems it doesn't know the signature of the 'null' opcode.
>
It gives no value back.
Something like this:
method value:sym<null>($/) {
my $pir := 'dummy';
make PAST::Val.new( :value($pir), :node($/) );
}
gives back the value 'dummy', but how to get the correct value in the
$pir variable?
-- Gerd
More information about the parrot-dev
mailing list