summary refs log tree commit diff
diff options
context:
space:
mode:
-rw-r--r--database.h23
1 files changed, 14 insertions, 9 deletions
diff --git a/database.h b/database.h
index 0494851..1837a9f 100644
--- a/database.h
+++ b/database.h
@@ -32,16 +32,21 @@
 
 enum { DatabaseVersion = 0 };
 
+#define ENUM_TYPE \
+	X(Privmsg, "privmsg") \
+	X(Notice, "notice") \
+	X(Action, "action") \
+	X(Join, "join") \
+	X(Part, "part") \
+	X(Quit, "quit") \
+	X(Kick, "kick") \
+	X(Nick, "nick") \
+	X(Topic, "topic")
+
 enum Type {
-	Privmsg,
-	Notice,
-	Action,
-	Join,
-	Part,
-	Quit,
-	Kick,
-	Nick,
-	Topic,
+#define X(id, _) id,
+	ENUM_TYPE
+#undef X
 };
 
 static bool verbose;