]> granicus.if.org Git - yasm/commitdiff
re2c-parser.y: Work around a bug in Bison 2.1; Bison 2.1 generates bad code if both
authorPeter Johnson <peter@tortall.net>
Thu, 5 Oct 2006 06:07:59 +0000 (06:07 -0000)
committerPeter Johnson <peter@tortall.net>
Thu, 5 Oct 2006 06:07:59 +0000 (06:07 -0000)
YYPARSE_PARAM and __STDC__ are undefined.

svn path=/trunk/yasm/; revision=1641

tools/re2c/re2c-parser.y

index a00279c31af34d33ddf76bbc2a34c3ff5e4d1d46..998cdb05724b11d07eb54f98ad06a1a3845252c0 100644 (file)
@@ -5,6 +5,10 @@
 #include <stdlib.h>
 #include "tools/re2c/globals.h"
 #include "tools/re2c/parse.h"
+
+/* Work around bug in Bison 2.1 */
+#define YYPARSE_PARAM  unused
+
 int yylex(void);
 void yyerror(const char*);
 
@@ -169,7 +173,7 @@ void parse(FILE *i, FILE *o){
     line_source(o, Scanner_line(in));
 
     while(Scanner_echo(in, o)){
-       yyparse();
+       yyparse(NULL);
        if(spec)
            genCode(o, spec);
        line_source(o, Scanner_line(in));