X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/1e9798d5699ca67718fd3b0d6baa9abcf27e6cd3..e9f87b5b7df2e328d2e4196d276c0d96594c906b:/src/symtab.c diff --git a/src/symtab.c b/src/symtab.c index 5ba5ca25..57ef636e 100644 --- a/src/symtab.c +++ b/src/symtab.c @@ -1,5 +1,5 @@ /* Symbol table manager for Bison, - Copyright (C) 1984, 1989, 2000 Free Software Foundation, Inc. + Copyright 1984, 1989, 2000, 2001 Free Software Foundation, Inc. This file is part of Bison, the GNU Compiler Compiler. @@ -20,7 +20,6 @@ #include "system.h" -#include "xalloc.h" #include "symtab.h" #include "gram.h" @@ -56,10 +55,10 @@ bucket_new (const char *tag, int hashval) res->next = NULL; res->tag = xstrdup (tag); res->type_name = NULL; - res->value = 0; + res->value = -1; res->prec = 0; res->assoc = right_assoc; - res->user_token_number = 0; + res->user_token_number = SUNDEF; res->alias = NULL; res->class = unknown_sym; @@ -143,6 +142,7 @@ free_symtab (void) if (bp->type_name) XFREE (bp->type_name); #endif + XFREE (bp->tag); XFREE (bp); bp = bptmp; }