]> git.saurik.com Git - bison.git/blobdiff - src/system.h
Rename struniq to uniqstr, to avoid collision with <string.h>.
[bison.git] / src / system.h
index 9aa6ea8379d58452edeb9cfd8963cb6c8c5986d7..1b2459e03028255e0d83b761c80139920b42781a 100644 (file)
@@ -1,4 +1,4 @@
-/* system-dependent definitions for Bison.
+/* System-dependent definitions for Bison.
    Copyright (C) 2000, 2001, 2002 Free Software Foundation, Inc.
 
    This program is free software; you can redistribute it and/or modify
@@ -41,7 +41,8 @@ char *alloca ();
 
 #include <stdio.h>
 
-#include <assert.h>
+/* Verify a requirement at compile-time (unlike assert, which is runtime).  */
+#define verify(name, assertion) struct name {char name[(assertion) ? 1 : -1];}
 
 #if HAVE_SYS_TYPES_H
 # include <sys/types.h>
@@ -129,6 +130,14 @@ void *memrchr (const void *s, int c, size_t n);
 | GCC extensions.  |
 `-----------------*/
 
+/* Use this to suppress gcc's `...may be used before initialized'
+   warnings.  */
+#ifdef lint
+# define IF_LINT(Code) Code
+#else
+# define IF_LINT(Code) /* empty */
+#endif
+
 #ifndef __attribute__
 /* This feature is available in gcc versions 2.5 and later.  */
 # if !defined (__GNUC__) || __GNUC__ < 2 || \