[svn:parrot] r41705 - branches/pcc_reapply/src/call

allison at svn.parrot.org allison at svn.parrot.org
Sun Oct 4 18:34:09 UTC 2009


Author: allison
Date: Sun Oct  4 18:34:08 2009
New Revision: 41705
URL: https://trac.parrot.org/parrot/changeset/41705

Log:
[pcc] Also mark the named argument as used when its pulled into the slurpy,
for later error checking.

Modified:
   branches/pcc_reapply/src/call/args.c

Modified: branches/pcc_reapply/src/call/args.c
==============================================================================
--- branches/pcc_reapply/src/call/args.c	Sun Oct  4 18:22:54 2009	(r41704)
+++ branches/pcc_reapply/src/call/args.c	Sun Oct  4 18:34:08 2009	(r41705)
@@ -962,6 +962,10 @@
                                 !VTABLE_exists_keyed_str(interp, named_used_list, name)) {
                             VTABLE_set_pmc_keyed_str(interp, collect_named, name,
                                     VTABLE_get_pmc_keyed_str(interp, call_object, name));
+                            /* Mark the name as used, cannot be filled again. */
+                            if (PMC_IS_NULL(named_used_list)) /* Only created if needed. */
+                                named_used_list = pmc_new(interp, enum_class_Hash);
+                            VTABLE_set_integer_keyed_str(interp, named_used_list, name, 1);
                             named_count++;
                         }
                     }


More information about the parrot-commits mailing list