Branch: Tag:

2001-03-05

2001-03-05 21:32:53 by Henrik Grubbström (Grubba) <grubba@grubba.org>

Support for naming of types in USE_PIKE_TYPE-mode.
Fixed memory-leak in USE_PIKE_TYPE-mode.

Rev: src/language.yacc:1.232
Rev: src/pike_types.c:1.161
Rev: src/pike_types.h:1.62
Rev: src/svalue.h:1.78

110:   /* This is the grammar definition of Pike. */      #include "global.h" - RCSID("$Id: language.yacc,v 1.231 2001/03/03 17:51:24 grubba Exp $"); + RCSID("$Id: language.yacc,v 1.232 2001/03/05 21:32:52 grubba Exp $");   #ifdef HAVE_MEMORY_H   #include <memory.h>   #endif
1175:       push_object_type(0, p?(p->id):0);    } + #ifdef USE_PIKE_TYPE +  /* Attempt to name the type. */ +  if (Pike_compiler->last_identifier) { +  push_type_name(Pike_compiler->last_identifier); +  } + #endif /* USE_PIKE_TYPE */    pop_stack();    free_node($1);    }
1292:    }    }    push_object_type(0, p?(p->id):0); + #ifdef USE_PIKE_TYPE +  /* Attempt to name the type. */ +  if (Pike_sp[-2].type == T_STRING) { +  push_type_name(Pike_sp[-2].u.string); +  } + #endif /* USE_PIKE_TYPE */    pop_n_elems(2);    }    ;