- if (insert) {
- if (b->b_type == NAME) {
- warn("%s redefined\n", name);
- f = b->b_args;
- b->b_args = value->b_args;
- value->b_args = f;
- } else if (value->b_type == VAR)
- fatal("%s redefined\n", name);
- while (f = value->b_next) {
- value->b_next = f->b_next;
- free(f->b_name);
- free(f);
+ if (action != LOOKUP) {
+ if (action != INSERT || s->s_type != CONST) {
+ sprintf(buf, "%s redefined", name);
+ yyerror(buf);