Branch: Tag:

1998-04-19

1998-04-19 03:17:37 by Per Hedbor <ph@opera.com>

The message 'Error in constant definition' now only shows up if it is the first error found. This to avoid confusing errors (since you get a 'Error in constant definition' for each and every constant definition after the first error)

Rev: src/language.yacc:1.85

171:   /* This is the grammar definition of Pike. */      #include "global.h" - RCSID("$Id: language.yacc,v 1.84 1998/04/19 00:13:18 grubba Exp $"); + RCSID("$Id: language.yacc,v 1.85 1998/04/19 03:17:37 per Exp $");   #ifdef HAVE_MEMORY_H   #include <memory.h>   #endif
471:    yyerror("Constant definition is not constant.");    add_constant($1->u.sval.u.string,0, current_modifiers); /* Prototype */    } else { +  if(!num_parse_error) +  {    tmp=eval_low($3);    if(tmp < 1)    {
481:    pop_stack();    }    } +  }    if($3) free_node($3);    free_node($1);    }