summaryrefslogtreecommitdiff
path: root/decoder/have_64_bits.h
diff options
context:
space:
mode:
authorgraehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-24 21:17:51 +0000
committergraehl <graehl@ec762483-ff6d-05da-a07a-a48fb63a330f>2010-07-24 21:17:51 +0000
commit22e857a27ab9755b1f8655b0dcd94ac77cb790b8 (patch)
tree57a5a30ae671b894f5fad72d21b3e3d083e7b884 /decoder/have_64_bits.h
parentefe34cdd3bcaded007ce387e61840c65adbb4eab (diff)
sparse_vector non-const [], consistently use default ctor, operator bool instead of explicit 0
git-svn-id: https://ws10smt.googlecode.com/svn/trunk@398 ec762483-ff6d-05da-a07a-a48fb63a330f
Diffstat (limited to 'decoder/have_64_bits.h')
-rwxr-xr-xdecoder/have_64_bits.h17
1 files changed, 17 insertions, 0 deletions
diff --git a/decoder/have_64_bits.h b/decoder/have_64_bits.h
new file mode 100755
index 00000000..d1e6064f
--- /dev/null
+++ b/decoder/have_64_bits.h
@@ -0,0 +1,17 @@
+#ifndef HAVE_64_BITS_H
+#define HAVE_64_BITS_H
+
+#include <stdint.h>
+
+#undef HAVE_64_BITS
+
+#if INTPTR_MAX == INT32_MAX
+# define HAVE_64_BITS 0
+#elif INTPTR_MAX >= INT64_MAX
+# define HAVE_64_BITS 1
+#else
+# error "couldn't tell if HAVE_64_BITS from INTPTR_MAX INT32_MAX INT64_MAX"
+#endif
+
+
+#endif