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.429 2008/05/30 20:20:23 grubba Exp $ + || $Id: language.yacc,v 1.430 2008/06/12 15:59:49 grubba Exp $   */      %pure_parser      %token TOK_ARROW      /*    * Basic value pushing    */   %token TOK_CONSTANT TOK_FLOAT TOK_STRING
pike.git/src/language.yacc:4507:    str,    type,    def);   }      /* Mark local variables declared in a multi-assign or sscanf expression    * as used. */   static void mark_lvalues_as_used(node *n)   {    while (n && n->token == F_LVALUE_LIST) { -  if (CAR(n)->token == F_ARRAY_LVALUE) { +  if (!CAR(n)) { +  /* Can happen if a variable hasn't been declared. */ +  } else if (CAR(n)->token == F_ARRAY_LVALUE) {    mark_lvalues_as_used(CAAR(n));    } else if ((CAR(n)->token == F_LOCAL) && !(CAR(n)->u.integer.b)) {    Pike_compiler->compiler_frame->variable[CAR(n)->u.integer.a].flags |=    LOCAL_VAR_IS_USED;    }    n = CDR(n);    }   }      #if 0