+/* Extra internal type checking? */
+extern int suppress_checking;
+extern void die P_((const char *, const char *, int));
+
+#ifdef ENABLE_CHECKING
+
+#define CHECK(check,msg) ((check || suppress_checking \
+ ? (void) 0 \
+ : die (msg, __FILE__, __LINE__)), \
+ 0)
+
+/* Let's get some compile-time checking too. */
+#undef NO_UNION_TYPE
+
+#else
+
+/* Produce same side effects and result, but don't complain. */
+#define CHECK(check,msg) ((check),0)
+
+#endif
+
+/* Used for making sure that Emacs is compilable in all
+ conigurations. */
+
+#ifdef USE_LISP_UNION_TYPE
+#undef NO_UNION_TYPE
+#endif
+
+/* Define an Emacs version of "assert", since some system ones are
+ flaky. */
+#ifndef ENABLE_CHECKING
+#define eassert(X) (void) 0
+#else /* ENABLE_CHECKING */
+#if defined (__GNUC__) && __GNUC__ >= 2 && defined (__STDC__)
+#define eassert(cond) CHECK(cond,"assertion failed: " #cond)
+#else
+#define eassert(cond) CHECK(cond,"assertion failed")
+#endif
+#endif /* ENABLE_CHECKING */
+