-/* Bison Grammar Parser -*- C -*-
+%{/* Bison Grammar Parser -*- C -*-
Copyright (C) 2002, 2003, 2004 Free Software Foundation, Inc.
02111-1307 USA
*/
-
-%debug
-%defines
-%locations
-%pure-parser
-%error-verbose
-%defines
-%name-prefix="gram_"
-
-%{
#include "system.h"
#include "complain.h"
int current_prec = 0;
%}
+%debug
+%defines
+%locations
+%pure-parser
+%error-verbose
+%defines
+%name-prefix="gram_"
+
%initial-action
{
/* Bison's grammar can initial empty locations, hence a default
{
int i;
YYLTYPE loc;
- loc.start = loc.end = rhs[n].end;
+
+ /* SGI MIPSpro 7.4.1m miscompiles "loc.start = loc.end = rhs[n].end;".
+ The bug is fixed in 7.4.2m, but play it safe for now. */
+ loc.start = rhs[n].end;
+ loc.end = rhs[n].end;
/* Ignore empty nonterminals the start of the the right-hand side.
Do not bother to ignore them at the end of the right-hand side,