pike.git / src / language.yacc

version» Context lines:

pike.git/src/language.yacc:1:   /* -*- c -*-   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: language.yacc,v 1.343 2006/03/02 10:39:47 grubba Exp $ + || $Id: language.yacc,v 1.344 2006/04/02 16:42:23 grubba Exp $   */      %pure_parser      %token TOK_ARROW      /*    * Basic value pushing    */   %token TOK_CONSTANT TOK_FLOAT TOK_STRING
pike.git/src/language.yacc:106:   %left TOK_LSH TOK_RSH   %left '+' '-'   %left '*' '%' '/'   %right TOK_NOT '~'   %nonassoc TOK_INC TOK_DEC      %{   /* This is the grammar definition of Pike. */      #include "global.h" - RCSID("$Id: language.yacc,v 1.343 2006/03/02 10:39:47 grubba Exp $"); + RCSID("$Id: language.yacc,v 1.344 2006/04/02 16:42:23 grubba Exp $");   #ifdef HAVE_MEMORY_H   #include <memory.h>   #endif      #include "interpret.h"   #include "array.h"   #include "object.h"   #include "stralloc.h"   #include "las.h"   #include "interpret.h"
pike.git/src/language.yacc:3986:    if(str->size_shift)    my_yyerror("Local variables cannot be of type of 'void'.\n");    else    my_yyerror("Local variable '%s' is void.\n",STR0(str));    }    }       debug_malloc_touch(def);    debug_malloc_touch(type);    debug_malloc_touch(str); -  reference_shared_string(str); +     if (frame->current_number_of_locals == MAX_LOCAL-1)    {    yyerror("Too many local variables."); -  +  free_type(type); +  if (def) free_node(def);    return -1;    }else { -  +  reference_shared_string(str);   #ifdef PIKE_DEBUG    check_type_string(type);   #endif /* PIKE_DEBUG */    if (pike_types_le(type, void_type_string)) {    if (Pike_compiler->compiler_pass != 1) {    yywarning("Declaring local variable with type void "    "(converted to type zero).");    }    free_type(type);    copy_pike_type(type, zero_type_string);