[svn:parrot] r44577 - in branches/exceptions_refactor/src: ops pmc

tene at svn.parrot.org tene at svn.parrot.org
Tue Mar 2 02:10:11 UTC 2010


Author: tene
Date: Tue Mar  2 02:10:08 2010
New Revision: 44577
URL: https://trac.parrot.org/parrot/changeset/44577

Log:
Work around a bug somewhere with attributes in subclasses of PMCs.

Modified:
   branches/exceptions_refactor/src/ops/core.ops
   branches/exceptions_refactor/src/pmc/exception.pmc

Modified: branches/exceptions_refactor/src/ops/core.ops
==============================================================================
--- branches/exceptions_refactor/src/ops/core.ops	Mon Mar  1 19:59:08 2010	(r44576)
+++ branches/exceptions_refactor/src/ops/core.ops	Tue Mar  2 02:10:08 2010	(r44577)
@@ -782,7 +782,7 @@
                 EXCEPTION_UNIMPLEMENTED,
                 Parrot_str_new_constant(interp, "Not a throwable object"));
 
-    VTABLE_set_attr_str(interp, except, Parrot_str_new_constant(interp, "resume"), resume);
+    VTABLE_set_pmc_keyed_str(interp, except, Parrot_str_new_constant(interp, "resume"), resume);
     dest = Parrot_ex_throw_from_op(interp, except, ret);
     goto ADDRESS(dest);
 }

Modified: branches/exceptions_refactor/src/pmc/exception.pmc
==============================================================================
--- branches/exceptions_refactor/src/pmc/exception.pmc	Mon Mar  1 19:59:08 2010	(r44576)
+++ branches/exceptions_refactor/src/pmc/exception.pmc	Tue Mar  2 02:10:08 2010	(r44577)
@@ -463,6 +463,20 @@
 
 /*
 
+=item C<void set_pmc_keyed_str(STRING *key, PMC *value)>
+
+Sets the PMC value for C<*key>.
+
+=cut
+
+*/
+
+    VTABLE void set_pmc_keyed_str(STRING *key, PMC *value) {
+        SELF.set_attr_str(key, value);
+    }
+
+/*
+
 =item C<void set_pointer(void *context)>
 
 Store a context for the handler iterator.


More information about the parrot-commits mailing list