commit | a7a9990f48d7e45463b0c50986805973956fdb4c | [log] [tgz] |
---|---|---|
author | gdt <gdt> | Mon Dec 22 16:07:52 2003 +0000 |
committer | gdt <gdt> | Mon Dec 22 16:07:52 2003 +0000 |
tree | 57a40b0c7af971c3fc7256e452b90f32897470de | |
parent | 297602162c89b10f6ee41c21e6302bcc51199a3d [diff] [blame] |
comments about struct list
diff --git a/lib/linklist.h b/lib/linklist.h index ace6dee..331135f 100644 --- a/lib/linklist.h +++ b/lib/linklist.h
@@ -36,7 +36,12 @@ { struct listnode *head; struct listnode *tail; + /* invariant: count is the number of listnodes in the list */ unsigned int count; + /* + * Returns -1 if val1 < val2, 0 if equal?, 1 if val1 > val2. + * Used as definition of sorted for listnode_add_sort + */ int (*cmp) (void *val1, void *val2); void (*del) (void *val); };