]> pd.if.org Git - pdclib/blobdiff - includes/iso646.h
Initial load with header templates and some first declarations.
[pdclib] / includes / iso646.h
diff --git a/includes/iso646.h b/includes/iso646.h
new file mode 100644 (file)
index 0000000..cc8be74
--- /dev/null
@@ -0,0 +1,32 @@
+// ----------------------------------------------------------------------------
+// $Id$
+// ----------------------------------------------------------------------------
+// Public Domain C Library - http://pdclib.sourceforge.net
+// This code is Public Domain. Use, modify, and redistribute at will.
+// ----------------------------------------------------------------------------
+// Provides "readable" aliases for bit operators.
+// ----------------------------------------------------------------------------
+
+#ifndef __ISO646_H
+#define __ISO646_H __ISO646_H
+
+// ----------------------------------------------------------------------------
+// DEFINES
+
+#ifndef __cplusplus
+
+#define and &&
+#define and_eq &=
+#define bitand &
+#define bitor |
+#define compl ~
+#define not !
+#define not_eq !=
+#define or ||
+#define or_eq |=
+#define xor ^
+#define xor_eq ^=
+
+#endif // __cplusplus
+
+#endif // __ISO646_H