]> git.saurik.com Git - bison.git/commitdiff
lalr1.cc: don't leave macros define to nothing
authorAkim Demaille <akim@lrde.epita.fr>
Tue, 25 Sep 2012 12:14:57 +0000 (14:14 +0200)
committerAkim Demaille <akim@lrde.epita.fr>
Sat, 6 Oct 2012 17:53:45 +0000 (19:53 +0200)
* data/lalr1.cc (YY_SYMBOL_PRINT, YY_REDUCE_PRINT, YY_STACK_PRINT):
Define to something so that, for instance, "if (foo) YY_SYMBOL_PRINT"
is valid even when !YYDEBUG.

data/lalr1.cc

index 82e68244c299feda6eed205951fc803ace71ac1c..308290ad44bf3a967a7c68b34d445f4e20a1aac4 100644 (file)
@@ -335,9 +335,9 @@ do {                                        \
 #else /* !]b4_api_PREFIX[DEBUG */
 
 # define YYCDEBUG if (false) std::cerr
-# define YY_SYMBOL_PRINT(Title, Type, Value, Location)
-# define YY_REDUCE_PRINT(Rule)
-# define YY_STACK_PRINT()
+# define YY_SYMBOL_PRINT(Title, Type, Value, Location) YYUSE(Type)
+# define YY_REDUCE_PRINT(Rule)        static_cast<void>(0)
+# define YY_STACK_PRINT()             static_cast<void>(0)
 
 #endif /* !]b4_api_PREFIX[DEBUG */