chiark / gitweb /
Add innduct-forall
[innduct.git] / innduct.h
index ddd17e69c59050b979bec2e8c131bd4869e11221..5a337cde6b5b55b8f3010c32dba444de1a8c35e6 100644 (file)
--- a/innduct.h
+++ b/innduct.h
 
 #define DUMPV(fmt,pfx,v) fprintf(f, " " #v "=" fmt, pfx v);
 
-#define FOR_CONN(conn) \
-  for ((conn)=LIST_HEAD(conns); (conn); (conn)=LIST_NEXT((conn)))
+#define FOR_LIST_NODE(nodevar, list) \
+  for ((nodevar)=LIST_HEAD(list); (nodevar); (nodevar)=LIST_NEXT((nodevar)))
+
+#define FOR_CONN(conn) FOR_LIST_NODE(conn, conns)
 
 /*----- doubly linked lists -----*/
 
@@ -184,7 +186,7 @@ extern double max_bad_data_ratio;
 extern int max_bad_data_initial;
 
 
-/*----- statistics -----*/
+/*----- article states, and statistics -----*/
 
 typedef enum {      /* in queue                 in conn->sent             */
   art_Unchecked,    /*   not checked, not sent    checking                */