pike.git / src / program.c

version» Context lines:

pike.git/src/program.c:1:   /*   || 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: program.c,v 1.619 2007/09/24 19:18:24 grubba Exp $ + || $Id: program.c,v 1.620 2007/09/25 16:56:53 grubba Exp $   */      #include "global.h"   #include "program.h"   #include "object.h"   #include "dynamic_buffer.h"   #include "pike_types.h"   #include "stralloc.h"   #include "las.h"   #include "lex.h"
pike.git/src/program.c:3060:    Pike_fatal("Invalid identifier type.\n");    }       if(p->identifiers[e].identifier_flags & ~IDENTIFIER_MASK)    Pike_fatal("Unknown flags in identifier flag field.\n");       if((p->identifiers[e].run_time_type!=T_MIXED) &&    (p->identifiers[e].run_time_type!=PIKE_T_GET_SET))    check_type(p->identifiers[e].run_time_type);    +  if (!IDENTIFIER_IS_EXTERN(p->identifiers[e].identifier_flags)) {    if(IDENTIFIER_IS_VARIABLE(p->identifiers[e].identifier_flags))    {    if( (p->identifiers[e].func.offset /* + OFFSETOF(object,storage)*/ ) &    (alignof_variable(p->identifiers[e].run_time_type)-1))    {    Pike_fatal("Variable %s offset is not properly aligned (%ld).\n",    p->identifiers[e].name->str,    PTRDIFF_T_TO_LONG(p->identifiers[e].func.offset));    }    } -  +  } else { +  /* FIXME: Check that ext_ref.depth and ext_ref.id are valid and +  * have matching identifier_flags. +  */ +  if (!(p->flags & PROGRAM_USES_PARENT)) { +  Pike_fatal("Identifier %d is an external reference, but " +  "PROGRAM_USES_PARENT hasn't been set.\n", +  e);    } -  +  } +  }       for(e=0;e<p->num_identifier_references;e++)    {    struct identifier *i;    if(p->identifier_references[e].inherit_offset > p->num_inherits)    Pike_fatal("Inherit offset is wrong!\n");       if(!p->inherits[p->identifier_references[e].inherit_offset].prog)    {    if(!(p->flags & PROGRAM_FINISHED))