# New Ticket Created by  Will Coleda 
# Please include the string:  [perl #41614]
# in the subject line of all future correspondence about this issue. 
# <URL: http://rt.perl.org/rt3/Ticket/Display.html?id=41614 >


In Tcl, I've tried to add an attribute to a TclProc PMC (a thin  
wrapper around .Sub) in my sandbox.

First, I have to override several methods in TclProc (copying them from

=item C<PMC* get_attr(INTVAL idx)>
=item C<PMC* get_attr_str(STRING *name)>
=item C<void set_attr(INTVAL idx, PMC *val)>
=item C<void set_attr_str(STRING *name, PMC *val)>

to avoid errors like:

set_attr_str() not implemented in class 'TclProc'

Once these are implemented, code like:

   setattribute $P1, 'source',     $P9

generates the exception:

  Can't set non-core object attribs

If I try to add the attribute before setting, it's worse:

   $P8 = getclass "TclProc"
   addattribute $P8, 'source'

  src/objects.c:1452: failed assertion `(class)->pmc_ext'





--
Will "Coke" Coleda
[EMAIL PROTECTED]


Reply via email to