Roman Zippel writes:
> If it's really enumerated data types, that's fine, but this example was > about bitfield masks.

Bryan Henderson writes:
Ah. In that case, enum is a pretty tortured way to declare it, though it does have the practical advantages over define that have been mentioned because the syntax is more rigorous.

I think the bit we're talking about is this:
Index: 2.6.12/fs/pnode.c
===================================================================
--- /dev/null
+++ 2.6.12/fs/pnode.c
@@ -0,0 +1,362 @@
+
+#define PNODE_MEMBER_VFS  0x01
+#define PNODE_SLAVE_VFS   0x02

I don't see how the following is tortured:
enum {
      PNODE_MEMBER_VFS  = 0x01,
      PNODE_SLAVE_VFS   = 0x02
}; In fact, I think it is more natural. An almost identical example even appears in K&R. Pekka
-
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to