Merged branch subtype-trunk into default.
[cacao.git] / src / toolbox / worklist.c
index 5c5d8de0890ad15eb58e98b25d3946ec3d214889..5489f1709d9cb61aeea1188b5e6de61d90f988ca 100644 (file)
 
    Authors: Christian Ullrich
 
-   $Id: worklist.c$
 
 */
 
-#include "mm/memory.h"
+#include "mm/memory.hpp"
 #include "toolbox/worklist.h"
 
 
@@ -112,6 +111,17 @@ bool wl_is_empty(worklist *w) {
        return (w->W_top == 0);
 }
 
+/*******************************************************************************
+wl_reset
+
+Empties the worklist.
+
+IN:     worklist *w    pointer to worklist created with wl_new
+*******************************************************************************/
+void wl_reset(worklist *w, int size) {
+       w->W_top = 0;
+       bv_reset(w->W_bv, size);
+}
 
 /*
  * These are local overrides for various environment variables in Emacs.