aboutsummaryrefslogtreecommitdiff
path: root/pair.h
diff options
context:
space:
mode:
Diffstat (limited to 'pair.h')
-rw-r--r--pair.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/pair.h b/pair.h
new file mode 100644
index 00000000..e3822a9b
--- /dev/null
+++ b/pair.h
@@ -0,0 +1,19 @@
+#ifndef PAIR_H
+#define PAIR_H
+
+#define PAIR(T, V) TEMPL2(pair, T, V)
+
+#endif /* PAIR_H */
+#if defined(T) && defined(V)
+
+typedef struct {
+ T left;
+ V right;
+} PAIR(T, V);
+
+INIT_F(PAIR(T, V));
+FREE_F(PAIR(T, V));
+FMT_F(PAIR(T, V));
+int DEEP_COPY(PAIR(T, V)) (PAIR(T, V)* dest, PAIR(T, V)* src);
+
+#endif