add FOR_EACH_IN_ARRAY
[libjh.git] / control_structures.c
diff --git a/control_structures.c b/control_structures.c
new file mode 100644 (file)
index 0000000..2891ea6
--- /dev/null
@@ -0,0 +1,4 @@
+// Copyright (2013) Jann Horn <jann@thejh.net>
+
+HEADER #define FOR_EACH_IN_ARRAY(array,array_len,element) \
+HEADER   for (typeof(array[0]) *element = &(array)[0]; element < &(array)[array_len]; element++)
\ No newline at end of file