pike.git / src / language.yacc

version» Context lines:

pike.git/src/language.yacc:105:   %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.240 2006/03/02 10:38:51 grubba Exp $"); + RCSID("$Id: language.yacc,v 1.241 2006/04/02 16:44:48 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:3643:    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)    {    yyerror("Too many local variables."); -  +  free_type(type); +  if (def) free_node(def);    return 0;    }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_string(type);    copy_shared_string(type, zero_type_string);