diff options
Diffstat (limited to '')
-rw-r--r-- | linked_list.h | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/linked_list.h b/linked_list.h index 666524be..a76c3443 100644 --- a/linked_list.h +++ b/linked_list.h @@ -6,8 +6,6 @@ #define LLIST(T) TP(llist__, T) #define LINK(T) TP(llist_link__, T) -#define LLIST_INIT(T) CONSTRUCTOR_GEN(llist, T, 0); -#define LLIST_FREE(T) TP(llist_free__, T) #define LLIST_CONS(T) TP(llist_cons__, T) #endif /* LINKED_LIST_H */ @@ -27,12 +25,15 @@ typedef struct { } LLIST(TYPE); int CONSTRUCTOR_DECL ( LLIST(TYPE) ); -int LLIST_FREE(TYPE) ( LLIST(TYPE)* ); +int FREE_DECL( LLIST(TYPE) ); int CONSTRUCTOR_DECL ( LINK(TYPE) ); +int CONSTRUCTOR_DECL ( LINK(TYPE), TYPE* val ); int LLIST_CONS(TYPE) ( LLIST(TYPE)* lst, TYPE* val); int DEEP_COPY(LLIST(TYPE)) ( LLIST(TYPE)* dest, LLIST(TYPE)* src ); +int APPEND(LLIST(TYPE)) ( LLIST(TYPE)* dest, LLIST(TYPE)* new ); + #endif /* TYPE */ |