Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Find out in program code, if a PMC-property is set?

0 views
Skip to first unread message

Gerd Pokorra

unread,
Aug 25, 2006, 2:06:17 PM8/25/06
to perl6-i...@perl.org
Hello!

In my program code I have the following lines:

/* get properties */
PMC *context_pmc = $3->vtable->getprop(interpreter, $3,
string_from_cstring(interpreter, "context", 7));

INTVAL i_type = context_pmc->vtable->type(interpreter, context_pmc);


This works fine, if I set the property "context" for the PMC in the
pasm-program.

If I don't set the property, the pasm-program stops with the message:
Null PMC access in type()
current instr.: '(null)' pc 45 (pcre_prop.pasm:33)

I what to find out in my program first, if the property is realy set,
but I don't know how to do that.

Best regards
Gerd Pokorra


Bob Rogers

unread,
Aug 25, 2006, 10:15:21 PM8/25/06
to pok...@uni-siegen.de, perl6-i...@perl.org
From: Gerd Pokorra <pok...@uni-siegen.de>
Date: Fri, 25 Aug 2006 20:06:17 +0200

Hello!

Best regards
Gerd Pokorra

See PMC_IS_NULL (defined in include/parrot/interpreter.h).

-- Bob Rogers
http://rgrjr.dyndns.org/

0 new messages