[svn:parrot] r47453 - in branches/gc_massacre: . config/gen/makefiles include/parrot src src/gc

cotto at svn.parrot.org cotto at svn.parrot.org
Tue Jun 8 07:15:53 UTC 2010


Author: cotto
Date: Tue Jun  8 07:15:52 2010
New Revision: 47453
URL: https://trac.parrot.org/parrot/changeset/47453

Log:
[list] move linked list code out of gc (function renaming still to come)

Added:
   branches/gc_massacre/include/parrot/list.h
      - copied unchanged from r47447, branches/gc_massacre/src/gc/list.h
   branches/gc_massacre/src/list.c
      - copied, changed from r47447, branches/gc_massacre/src/gc/list.c
Deleted:
   branches/gc_massacre/src/gc/list.c
   branches/gc_massacre/src/gc/list.h
Modified:
   branches/gc_massacre/MANIFEST
   branches/gc_massacre/config/gen/makefiles/root.in
   branches/gc_massacre/src/gc/gc_ms.c
   branches/gc_massacre/src/gc/gc_ms2.c
   branches/gc_massacre/src/gc/gc_tms.c

Modified: branches/gc_massacre/MANIFEST
==============================================================================
--- branches/gc_massacre/MANIFEST	Tue Jun  8 06:31:44 2010	(r47452)
+++ branches/gc_massacre/MANIFEST	Tue Jun  8 07:15:52 2010	(r47453)
@@ -1,7 +1,7 @@
 # ex: set ro:
 # $Id$
 #
-# generated by tools/dev/mk_manifest_and_skip.pl Thu Jun  3 16:29:37 2010 UT
+# generated by tools/dev/mk_manifest_and_skip.pl Tue Jun  8 07:10:53 2010 UT
 #
 # See below for documentation on the format of this file.
 #
@@ -972,6 +972,7 @@
 include/parrot/io_win32.h                                   [main]include
 include/parrot/key.h                                        [main]include
 include/parrot/library.h                                    [main]include
+include/parrot/list.h                                       [main]include
 include/parrot/longopt.h                                    [main]include
 include/parrot/memory.h                                     [main]include
 include/parrot/misc.h                                       [main]include
@@ -1290,8 +1291,6 @@
 src/gc/gc_ms2.c                                             []
 src/gc/gc_private.h                                         []
 src/gc/gc_tms.c                                             []
-src/gc/list.c                                               []
-src/gc/list.h                                               []
 src/gc/malloc.c                                             []
 src/gc/malloc_trace.c                                       []
 src/gc/mark_sweep.c                                         []
@@ -1320,6 +1319,7 @@
 src/key.c                                                   []
 src/libnci_test.def                                         []
 src/library.c                                               []
+src/list.c                                                  []
 src/longopt.c                                               []
 src/main.c                                                  []
 src/misc.c                                                  []

Modified: branches/gc_massacre/config/gen/makefiles/root.in
==============================================================================
--- branches/gc_massacre/config/gen/makefiles/root.in	Tue Jun  8 06:31:44 2010	(r47452)
+++ branches/gc_massacre/config/gen/makefiles/root.in	Tue Jun  8 07:15:52 2010	(r47453)
@@ -404,6 +404,7 @@
 	$(INC_DIR)/core_pmcs.h \
 	$(INC_DIR)/compiler.h \
 	$(INC_DIR)/cclass.h \
+	$(INC_DIR)/list.h \
 	include/pmc/pmc_callcontext.h
 
 # generated list of header files
@@ -454,7 +455,6 @@
     src/gc/mark_sweep$(O) \
     src/gc/system$(O) \
     src/gc/pool_allocator$(O) \
-    src/gc/list$(O) \
     src/global$(O) \
     src/global_setup$(O) \
     src/hash$(O) \
@@ -469,6 +469,7 @@
     src/call/context_accessors$(O) \
     src/key$(O) \
     src/library$(O) \
+    src/list$(O) \
     src/longopt$(O) \
     src/misc$(O) \
     src/multidispatch$(O) \
@@ -1277,13 +1278,13 @@
 
 src/gc/mark_sweep$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/mark_sweep.c
 
-src/gc/gc_ms$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/pool_allocator.h src/gc/list.h src/gc/gc_ms.c
+src/gc/gc_ms$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/pool_allocator.h src/gc/gc_ms.c
 
 src/gc/gc_inf$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/gc_inf.c
 
-src/gc/gc_tms$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/list.h src/gc/gc_tms.c
+src/gc/gc_tms$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/gc_tms.c
 
-src/gc/gc_ms2$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/list.h src/gc/gc_ms2.c
+src/gc/gc_ms2$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/gc_ms2.c
 
 src/gc/api$(O) : $(PARROT_H_HEADERS) src/gc/gc_private.h src/gc/api.c
 
@@ -1293,9 +1294,6 @@
 src/gc/pool_allocator$(O) : $(PARROT_H_HEADERS) \
 	src/gc/pool_allocator.h src/gc/pool_allocator.c
 
-src/gc/list$(O) : $(PARROT_H_HEADERS) \
-	src/gc/list.h src/gc/list.c
-
 src/hll$(O) : $(PARROT_H_HEADERS) src/hll.str $(INC_DIR)/dynext.h src/hll.c
 
 src/platform$(O) : $(PARROT_H_HEADERS) src/platform.c

Copied: branches/gc_massacre/include/parrot/list.h (from r47447, branches/gc_massacre/src/gc/list.h)
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ branches/gc_massacre/include/parrot/list.h	Tue Jun  8 07:15:52 2010	(r47453, copy of r47447, branches/gc_massacre/src/gc/list.h)
@@ -0,0 +1,168 @@
+/*
+Copyright (C) 2010, Parrot Foundation.
+$Id$
+
+=head1 NAME
+
+src/gc/list.h - Linked lists of allocated objects.
+
+=head1 DESCRIPTION
+
+Implementation of double linked lists used by various GC implementations.
+
+*/
+
+#ifndef PARROT_GC_LIST_H_GUARD
+#define PARROT_GC_LIST_H_GUARD
+
+/* Allocatable objects has headers to use in linked lists */
+typedef struct List_Item_Header {
+    struct List_Item_Header *prev;
+    struct List_Item_Header *next;
+
+#ifndef NDEBUG
+    struct Linked_List *owner;
+#endif
+} List_Item_Header;
+
+/* Double-linked list. */
+/* N.B. List doesn't _own_ items */
+typedef struct Linked_List {
+    struct List_Item_Header *first;
+    struct List_Item_Header *last;
+
+    /* Cache object count in list. We use it very often */
+    size_t count;
+} Linked_List;
+
+/* Such headers allocated in front of real objects. */
+/* There is helper macros to convert to/from real objects */
+#define Obj2LLH(p) ((List_Item_Header *)((char*)(p) - sizeof (List_Item_Header)))
+#define LLH2Obj_typed(p, type) ((type*)((char*)(p) + sizeof (List_Item_Header)))
+#define LLH2Obj(p) LLH2Obj_typed(p, void)
+
+#ifdef NDEBUG
+#  define SET_LIST_OWNER(l, i)
+#else
+#  define SET_LIST_OWNER(l, i) (i)->owner = (l);
+#endif
+
+#define LIST_APPEND(l, i)                   \
+do {                                        \
+    List_Item_Header *_item = (i);          \
+    Linked_List      *_list = (l);          \
+    (_item)->prev = (_item)->next = NULL;   \
+                                            \
+    if (_list->last) {                      \
+        _item->prev = _list->last;          \
+        _list->last->next = _item;          \
+    }                                       \
+                                            \
+    _list->last = _item;                    \
+                                            \
+    if (!_list->first)                      \
+        _list->first = _item;               \
+                                            \
+    SET_LIST_OWNER(_list, _item)            \
+    _list->count++;                         \
+} while (0);
+
+#define LIST_REMOVE(l, i)                   \
+do {                                        \
+    List_Item_Header *_item = (i);          \
+    Linked_List      *_list = (l);          \
+    List_Item_Header *next = _item->next;   \
+    List_Item_Header *prev = _item->prev;   \
+                                            \
+    PARROT_ASSERT(_list == _item->owner);   \
+                                            \
+    /* First _item */                       \
+    if (_list->first == _item)              \
+        _list->first = next;                \
+                                            \
+    if (_list->last == _item)               \
+        _list->last = prev;                 \
+                                            \
+    if (prev)                               \
+        prev->next = next;                  \
+    if (next)                               \
+        next->prev = prev;                  \
+                                            \
+    _list->count--;                         \
+} while (0)
+
+
+/* HEADERIZER BEGIN: src/gc/list.c */
+/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
+
+PARROT_EXPORT
+PARROT_CANNOT_RETURN_NULL
+struct Linked_List* Parrot_gc_allocate_linked_list(SHIM_INTERP);
+
+PARROT_EXPORT
+void Parrot_gc_destroy_linked_list(SHIM_INTERP, ARGMOD(Linked_List* list))
+        __attribute__nonnull__(2)
+        FUNC_MODIFIES(* list);
+
+PARROT_EXPORT
+void Parrot_gc_list_append(SHIM_INTERP,
+    ARGMOD(Linked_List *list),
+    ARGMOD(List_Item_Header *item))
+        __attribute__nonnull__(2)
+        __attribute__nonnull__(3)
+        FUNC_MODIFIES(*list)
+        FUNC_MODIFIES(*item);
+
+PARROT_EXPORT
+List_Item_Header* Parrot_gc_list_pop(PARROT_INTERP,
+    ARGIN(Linked_List *list))
+        __attribute__nonnull__(1)
+        __attribute__nonnull__(2);
+
+PARROT_EXPORT
+List_Item_Header* Parrot_gc_list_remove(SHIM_INTERP,
+    ARGMOD(Linked_List *list),
+    ARGMOD(List_Item_Header *item))
+        __attribute__nonnull__(2)
+        __attribute__nonnull__(3)
+        FUNC_MODIFIES(*list)
+        FUNC_MODIFIES(*item);
+
+int Parrot_gc_list_check(SHIM_INTERP, ARGIN(Linked_List *list))
+        __attribute__nonnull__(2);
+
+int Parrot_gc_list_is_owned(SHIM_INTERP,
+    ARGIN(Linked_List *list),
+    ARGIN(List_Item_Header *item))
+        __attribute__nonnull__(2)
+        __attribute__nonnull__(3);
+
+#define ASSERT_ARGS_Parrot_gc_allocate_linked_list \
+     __attribute__unused__ int _ASSERT_ARGS_CHECK = (0)
+#define ASSERT_ARGS_Parrot_gc_destroy_linked_list __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(list))
+#define ASSERT_ARGS_Parrot_gc_list_append __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(list) \
+    , PARROT_ASSERT_ARG(item))
+#define ASSERT_ARGS_Parrot_gc_list_pop __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(interp) \
+    , PARROT_ASSERT_ARG(list))
+#define ASSERT_ARGS_Parrot_gc_list_remove __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(list) \
+    , PARROT_ASSERT_ARG(item))
+#define ASSERT_ARGS_Parrot_gc_list_check __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(list))
+#define ASSERT_ARGS_Parrot_gc_list_is_owned __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
+       PARROT_ASSERT_ARG(list) \
+    , PARROT_ASSERT_ARG(item))
+/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
+/* HEADERIZER END: src/gc/list.c */
+
+#endif /* PARROT_GC_LIST_H_GUARD */
+
+/*
+ * Local variables:
+ *   c-file-style: "parrot"
+ * End:
+ * vim: expandtab shiftwidth=4:
+ */

Modified: branches/gc_massacre/src/gc/gc_ms.c
==============================================================================
--- branches/gc_massacre/src/gc/gc_ms.c	Tue Jun  8 06:31:44 2010	(r47452)
+++ branches/gc_massacre/src/gc/gc_ms.c	Tue Jun  8 07:15:52 2010	(r47453)
@@ -16,7 +16,7 @@
 
 #include "parrot/parrot.h"
 #include "gc_private.h"
-#include "list.h"
+#include "parrot/list.h"
 
 PARROT_DOES_NOT_RETURN
 static void failed_allocation(unsigned int line, unsigned long size) /* HEADERIZER SKIP */

Modified: branches/gc_massacre/src/gc/gc_ms2.c
==============================================================================
--- branches/gc_massacre/src/gc/gc_ms2.c	Tue Jun  8 06:31:44 2010	(r47452)
+++ branches/gc_massacre/src/gc/gc_ms2.c	Tue Jun  8 07:15:52 2010	(r47453)
@@ -14,8 +14,8 @@
 
 #include "parrot/parrot.h"
 #include "parrot/gc_api.h"
+#include "parrot/list.h"
 #include "gc_private.h"
-#include "list.h"
 #include "pool_allocator.h"
 
 #define PANIC_OUT_OF_MEM(size) failed_allocation(__LINE__, (size))

Modified: branches/gc_massacre/src/gc/gc_tms.c
==============================================================================
--- branches/gc_massacre/src/gc/gc_tms.c	Tue Jun  8 06:31:44 2010	(r47452)
+++ branches/gc_massacre/src/gc/gc_tms.c	Tue Jun  8 07:15:52 2010	(r47453)
@@ -15,7 +15,7 @@
 #include "parrot/parrot.h"
 #include "parrot/gc_api.h"
 #include "gc_private.h"
-#include "list.h"
+#include "parrot/list.h"
 #include "pool_allocator.h"
 
 #define PANIC_OUT_OF_MEM(size) failed_allocation(__LINE__, (size))

Deleted: branches/gc_massacre/src/gc/list.c
==============================================================================
--- branches/gc_massacre/src/gc/list.c	Tue Jun  8 07:15:52 2010	(r47452)
+++ /dev/null	00:00:00 1970	(deleted)
@@ -1,239 +0,0 @@
-/*
-Copyright (C) 2010, Parrot Foundation.
-$Id$
-
-=head1 NAME
-
-src/gc/list.c - Implementation of double linked lists.
-
-=head1 DESCRIPTION
-
-This code implements double linked list of GCable objects.
-
-=cut
-
-*/
-
-#include "parrot/parrot.h"
-#include "list.h"
-
-/* HEADERIZER HFILE: src/gc/list.h */
-
-/* HEADERIZER BEGIN: static */
-/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
-
-/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
-/* HEADERIZER END: static */
-
-/*
-
-=over 4
-
-=item C<struct Linked_List* Parrot_gc_allocate_linked_list(PARROT_INTERP)>
-
-Allocate a doubly link list
-
-=cut
-
-*/
-
-PARROT_EXPORT
-PARROT_CANNOT_RETURN_NULL
-struct Linked_List*
-Parrot_gc_allocate_linked_list(SHIM_INTERP)
-{
-    ASSERT_ARGS(Parrot_gc_allocate_linked_list)
-
-    Linked_List *res = (Linked_List*)mem_sys_allocate_zeroed(sizeof (Linked_List));
-    return res;
-}
-
-/*
-
-=item C<void Parrot_gc_destroy_linked_list(PARROT_INTERP, Linked_List* list)>
-
-Destroy the specified list (free up memory associated with the list)
-
-=cut
-
-*/
-
-PARROT_EXPORT
-void
-Parrot_gc_destroy_linked_list(SHIM_INTERP, ARGMOD(Linked_List* list))
-{
-    ASSERT_ARGS(Parrot_gc_destroy_linked_list)
-
-    mem_sys_free(list);
-}
-
-/*
-
-=item C<void Parrot_gc_list_append(PARROT_INTERP, Linked_List *list,
-List_Item_Header *item)>
-
-Append an item to the list
-
-=cut
-
-*/
-
-PARROT_EXPORT
-void
-Parrot_gc_list_append(SHIM_INTERP, ARGMOD(Linked_List *list), ARGMOD(List_Item_Header *item))
-{
-    ASSERT_ARGS(Parrot_gc_list_append)
-
-    item->prev = item->next = NULL;
-
-    if (list->last) {
-        item->prev = list->last;
-        list->last->next = item;
-    }
-
-    list->last = item;
-
-    if (!list->first)
-        list->first = item;
-
-    list->count++;
-#ifndef NDEBUG
-    item->owner = list;
-#endif
-}
-
-/*
-
-=item C<List_Item_Header* Parrot_gc_list_remove(PARROT_INTERP, Linked_List
-*list, List_Item_Header *item)>
-
-Remove an item from the list, returning the (pointer to) item
-
-=cut
-
-*/
-
-PARROT_EXPORT
-List_Item_Header*
-Parrot_gc_list_remove(SHIM_INTERP, ARGMOD(Linked_List *list), ARGMOD(List_Item_Header *item))
-{
-    ASSERT_ARGS(Parrot_gc_list_remove)
-
-    List_Item_Header *next = item->next;
-    List_Item_Header *prev = item->prev;
-
-    PARROT_ASSERT(list == item->owner);
-
-    /* First item */
-    if (list->first == item)
-        list->first = next;
-
-    if (list->last == item)
-        list->last = prev;
-
-    if (prev)
-        prev->next = next;
-    if (next)
-        next->prev = prev;
-
-    list->count--;
-    return item;
-}
-
-/*
-
-=item C<List_Item_Header* Parrot_gc_list_pop(PARROT_INTERP, Linked_List *list)>
-
-Pop an item off the list - i.e. get the first item in the list and remove it.
-
-=cut
-
-*/
-
-PARROT_EXPORT
-List_Item_Header*
-Parrot_gc_list_pop(PARROT_INTERP, ARGIN(Linked_List *list))
-{
-    ASSERT_ARGS(Parrot_gc_list_pop)
-
-    List_Item_Header *ret = list->first;
-    if (ret)
-        LIST_REMOVE(list, ret);
-    return ret;
-}
-
-/*
-
-=item C<int Parrot_gc_list_check(PARROT_INTERP, Linked_List *list)>
-
-Check the validity of the list
-
-=cut
-
-*/
-
-int
-Parrot_gc_list_check(SHIM_INTERP, ARGIN(Linked_List *list))
-{
-    ASSERT_ARGS(Parrot_gc_list_check)
-
-    List_Item_Header *tmp = list->first;
-    size_t counter = 0;
-
-    while (tmp) {
-        List_Item_Header *next = tmp->next;
-        PARROT_ASSERT(tmp->owner == list);
-        tmp = next;
-        ++counter;
-        PARROT_ASSERT(counter <= list->count);
-    }
-
-    return 1;
-}
-
-/*
-
-=item C<int Parrot_gc_list_is_owned(PARROT_INTERP, Linked_List *list,
-List_Item_Header *item)>
-
-Returns True if the is owned by the list
-
-=cut
-
-*/
-
-int
-Parrot_gc_list_is_owned(SHIM_INTERP, ARGIN(Linked_List *list), ARGIN(List_Item_Header *item))
-{
-    ASSERT_ARGS(Parrot_gc_list_is_owned)
-
-    List_Item_Header *tmp = list->first;
-
-#ifndef NDEBUG
-    if (item->owner != list)
-        return 0;
-#endif
-
-    while (tmp) {
-        if (tmp == item)
-            return 1;
-        tmp = tmp->next;
-    }
-
-    return 0;
-}
-
-/*
-
-=back
-
-=cut
-
-*/
-
-/*
- * Local variables:
- *   c-file-style: "parrot"
- * End:
- * vim: expandtab shiftwidth=4:
- */

Deleted: branches/gc_massacre/src/gc/list.h
==============================================================================
--- branches/gc_massacre/src/gc/list.h	Tue Jun  8 07:15:52 2010	(r47452)
+++ /dev/null	00:00:00 1970	(deleted)
@@ -1,168 +0,0 @@
-/*
-Copyright (C) 2010, Parrot Foundation.
-$Id$
-
-=head1 NAME
-
-src/gc/list.h - Linked lists of allocated objects.
-
-=head1 DESCRIPTION
-
-Implementation of double linked lists used by various GC implementations.
-
-*/
-
-#ifndef PARROT_GC_LIST_H_GUARD
-#define PARROT_GC_LIST_H_GUARD
-
-/* Allocatable objects has headers to use in linked lists */
-typedef struct List_Item_Header {
-    struct List_Item_Header *prev;
-    struct List_Item_Header *next;
-
-#ifndef NDEBUG
-    struct Linked_List *owner;
-#endif
-} List_Item_Header;
-
-/* Double-linked list. */
-/* N.B. List doesn't _own_ items */
-typedef struct Linked_List {
-    struct List_Item_Header *first;
-    struct List_Item_Header *last;
-
-    /* Cache object count in list. We use it very often */
-    size_t count;
-} Linked_List;
-
-/* Such headers allocated in front of real objects. */
-/* There is helper macros to convert to/from real objects */
-#define Obj2LLH(p) ((List_Item_Header *)((char*)(p) - sizeof (List_Item_Header)))
-#define LLH2Obj_typed(p, type) ((type*)((char*)(p) + sizeof (List_Item_Header)))
-#define LLH2Obj(p) LLH2Obj_typed(p, void)
-
-#ifdef NDEBUG
-#  define SET_LIST_OWNER(l, i)
-#else
-#  define SET_LIST_OWNER(l, i) (i)->owner = (l);
-#endif
-
-#define LIST_APPEND(l, i)                   \
-do {                                        \
-    List_Item_Header *_item = (i);          \
-    Linked_List      *_list = (l);          \
-    (_item)->prev = (_item)->next = NULL;   \
-                                            \
-    if (_list->last) {                      \
-        _item->prev = _list->last;          \
-        _list->last->next = _item;          \
-    }                                       \
-                                            \
-    _list->last = _item;                    \
-                                            \
-    if (!_list->first)                      \
-        _list->first = _item;               \
-                                            \
-    SET_LIST_OWNER(_list, _item)            \
-    _list->count++;                         \
-} while (0);
-
-#define LIST_REMOVE(l, i)                   \
-do {                                        \
-    List_Item_Header *_item = (i);          \
-    Linked_List      *_list = (l);          \
-    List_Item_Header *next = _item->next;   \
-    List_Item_Header *prev = _item->prev;   \
-                                            \
-    PARROT_ASSERT(_list == _item->owner);   \
-                                            \
-    /* First _item */                       \
-    if (_list->first == _item)              \
-        _list->first = next;                \
-                                            \
-    if (_list->last == _item)               \
-        _list->last = prev;                 \
-                                            \
-    if (prev)                               \
-        prev->next = next;                  \
-    if (next)                               \
-        next->prev = prev;                  \
-                                            \
-    _list->count--;                         \
-} while (0)
-
-
-/* HEADERIZER BEGIN: src/gc/list.c */
-/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
-
-PARROT_EXPORT
-PARROT_CANNOT_RETURN_NULL
-struct Linked_List* Parrot_gc_allocate_linked_list(SHIM_INTERP);
-
-PARROT_EXPORT
-void Parrot_gc_destroy_linked_list(SHIM_INTERP, ARGMOD(Linked_List* list))
-        __attribute__nonnull__(2)
-        FUNC_MODIFIES(* list);
-
-PARROT_EXPORT
-void Parrot_gc_list_append(SHIM_INTERP,
-    ARGMOD(Linked_List *list),
-    ARGMOD(List_Item_Header *item))
-        __attribute__nonnull__(2)
-        __attribute__nonnull__(3)
-        FUNC_MODIFIES(*list)
-        FUNC_MODIFIES(*item);
-
-PARROT_EXPORT
-List_Item_Header* Parrot_gc_list_pop(PARROT_INTERP,
-    ARGIN(Linked_List *list))
-        __attribute__nonnull__(1)
-        __attribute__nonnull__(2);
-
-PARROT_EXPORT
-List_Item_Header* Parrot_gc_list_remove(SHIM_INTERP,
-    ARGMOD(Linked_List *list),
-    ARGMOD(List_Item_Header *item))
-        __attribute__nonnull__(2)
-        __attribute__nonnull__(3)
-        FUNC_MODIFIES(*list)
-        FUNC_MODIFIES(*item);
-
-int Parrot_gc_list_check(SHIM_INTERP, ARGIN(Linked_List *list))
-        __attribute__nonnull__(2);
-
-int Parrot_gc_list_is_owned(SHIM_INTERP,
-    ARGIN(Linked_List *list),
-    ARGIN(List_Item_Header *item))
-        __attribute__nonnull__(2)
-        __attribute__nonnull__(3);
-
-#define ASSERT_ARGS_Parrot_gc_allocate_linked_list \
-     __attribute__unused__ int _ASSERT_ARGS_CHECK = (0)
-#define ASSERT_ARGS_Parrot_gc_destroy_linked_list __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(list))
-#define ASSERT_ARGS_Parrot_gc_list_append __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(list) \
-    , PARROT_ASSERT_ARG(item))
-#define ASSERT_ARGS_Parrot_gc_list_pop __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(interp) \
-    , PARROT_ASSERT_ARG(list))
-#define ASSERT_ARGS_Parrot_gc_list_remove __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(list) \
-    , PARROT_ASSERT_ARG(item))
-#define ASSERT_ARGS_Parrot_gc_list_check __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(list))
-#define ASSERT_ARGS_Parrot_gc_list_is_owned __attribute__unused__ int _ASSERT_ARGS_CHECK = (\
-       PARROT_ASSERT_ARG(list) \
-    , PARROT_ASSERT_ARG(item))
-/* Don't modify between HEADERIZER BEGIN / HEADERIZER END.  Your changes will be lost. */
-/* HEADERIZER END: src/gc/list.c */
-
-#endif /* PARROT_GC_LIST_H_GUARD */
-
-/*
- * Local variables:
- *   c-file-style: "parrot"
- * End:
- * vim: expandtab shiftwidth=4:
- */

Copied and modified: branches/gc_massacre/src/list.c (from r47447, branches/gc_massacre/src/gc/list.c)
==============================================================================
--- branches/gc_massacre/src/gc/list.c	Tue Jun  8 04:16:13 2010	(r47447, copy source)
+++ branches/gc_massacre/src/list.c	Tue Jun  8 07:15:52 2010	(r47453)
@@ -15,7 +15,7 @@
 */
 
 #include "parrot/parrot.h"
-#include "list.h"
+#include "parrot/list.h"
 
 /* HEADERIZER HFILE: src/gc/list.h */
 


More information about the parrot-commits mailing list