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.763 2009/06/21 17:16:06 grubba Exp $ + || $Id: program.c,v 1.764 2009/06/22 12:08:51 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:3000:    case T_FLOAT: return ALIGNOF(FLOAT_TYPE);    case T_INT: return ALIGNOF(INT_TYPE);    case PIKE_T_FREE:    case PIKE_T_GET_SET: return 1;    default: return ALIGNOF(void *);    }   }      #ifdef PIKE_DEBUG    - void dump_program_tables (struct program *p, int indent) + void dump_program_tables (const struct program *p, int indent)   {    int d;       if (!p) {    fprintf(stderr, "%*sProgram: NULL\n\n", indent, "");    return;    }       fprintf(stderr,    "%*sProgram flags: 0x%04x\n\n",
pike.git/src/program.c:5904:    *    * It now (Pike 7.3.33 and later) looks up the most recent definition    * in the most recent inherit.    *    * In Pike 7.3.23 -- 7.3.32 it looked up the most recent definition    * with the least inherit depth.    *    * In Pike 7.3.22 and prior, it looked up the last definition regardless    * of inherit depth, unless there was a definition in the current program.    * +  * Note also that the changed handling of mixin's in Pike 7.7.40 affects +  * the behaviour when using static inherit. See F below. +  *    * Example:    *    * class A {    * int foo() {}    * }    *    * class B {    * int foo() {}    * inherit A;    * }    *    * class C {    * inherit B;    * }    *    * class D {    * inherit B;    * inherit C;    * }    * -  +  * class E { +  * int foo() {} +  * } +  * +  * class F { +  * inherit A; +  * static inherit E; +  * } +  *    * Lookup of identifier "foo" in D():    *    * D-+-B-+-foo Pike 7.3.23 --- Pike 7.3.32    * | |    * | +-A---foo    * |    * +-C---B-+-foo Pike 7.3.33 ---    * |    * +-A---foo --- Pike 7.3.22    *
pike.git/src/program.c:5945:    *    * C---B-+-foo Pike 7.3.23 ---    * |    * +-A---foo --- Pike 7.3.22    *    * Lookup of identifier "foo" in B():    *    * B-+-foo All versions of Pike    * |    * +-A---foo +  * +  * External lookup of identifier "foo" in E(): +  * +  * F-+-A---foo --- Pike 7.7.33 +  * | +  * +-E---foo Pike 7.7.34 ---    */   int really_low_find_shared_string_identifier(struct pike_string *name,    struct program *prog,    int flags)   {    struct reference *funp;    struct identifier *fun;    int id, i, depth, last_inh;      #if 0