[svn:parrot] r43372 - branches/pmc_freeze_cleanup/src

plobsing at svn.parrot.org plobsing at svn.parrot.org
Sat Jan 2 20:24:24 UTC 2010


Author: plobsing
Date: Sat Jan  2 20:24:22 2010
New Revision: 43372
URL: https://trac.parrot.org/parrot/changeset/43372

Log:
without EXTRA_IS_PROP_HASH, there should be no additional data once we think we're done reading the image

Modified:
   branches/pmc_freeze_cleanup/src/pmc_freeze.c

Modified: branches/pmc_freeze_cleanup/src/pmc_freeze.c
==============================================================================
--- branches/pmc_freeze_cleanup/src/pmc_freeze.c	Sat Jan  2 14:34:08 2010	(r43371)
+++ branches/pmc_freeze_cleanup/src/pmc_freeze.c	Sat Jan  2 20:24:22 2010	(r43372)
@@ -699,25 +699,25 @@
     List * const todo           = (List *)PMC_data(info->todo);
     const int    thawing        = info->what == VISIT_THAW_NORMAL;
 
-    /* can't cache upper limit, visit may append items */
-    do {
-        (info->visit_pmc_now)(interp, current, info);
+    (info->visit_pmc_now)(interp, current, info);
 
-        while ((list_item = (PMC **)Parrot_pmc_array_shift(interp, todo, enum_type_PMC))) {
-            current = *list_item;
-            if (!current)
-                Parrot_ex_throw_from_c_args(interp, NULL, 1,
-                        "NULL current PMC in visit_loop_todo_list");
+    /* can't cache upper limit, visit may append items */
+    while ((list_item = (PMC **)Parrot_pmc_array_shift(interp, todo, enum_type_PMC))) {
+        current = *list_item;
+        if (!current)
+            Parrot_ex_throw_from_c_args(interp, NULL, 1,
+                    "NULL current PMC in visit_loop_todo_list");
 
-            PARROT_ASSERT(current->vtable);
+        PARROT_ASSERT(current->vtable);
 
-            VTABLE_visit(interp, current, info);
+        VTABLE_visit(interp, current, info);
 
-            VISIT_PMC(interp, info, PMC_metadata(current));
-        }
-        current = NULL;
+        VISIT_PMC(interp, info, PMC_metadata(current));
     }
-    while (thawing && INFO_HAS_DATA(info));
+
+    if (thawing)
+        /* we're done reading the image */
+        PARROT_ASSERT(!INFO_HAS_DATA(info));
 
     if (thawing) {
         /* on thawing call thawfinish for each processed PMC */


More information about the parrot-commits mailing list