Branch: Tag:

1999-09-18

1999-09-18 09:21:30 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

name tracking for constants underway (not yet finished)

Rev: src/docode.c:1.51
Rev: src/interpreter.h:1.13
Rev: src/language.yacc:1.123
Rev: src/las.c:1.88
Rev: src/lex.c:1.66
Rev: src/object.c:1.82
Rev: src/object.h:1.29
Rev: src/pike_types.h:1.21
Rev: src/program.c:1.151
Rev: src/program.h:1.59
Rev: src/program_areas.h:1.6
Rev: src/testsuite.in:1.197

4:   ||| See the files COPYING and DISCLAIMER for more information.   \*/   #include "global.h" - RCSID("$Id: docode.c,v 1.50 1999/09/16 23:56:09 hubbe Exp $"); + RCSID("$Id: docode.c,v 1.51 1999/09/18 09:21:17 hubbe Exp $");   #include "las.h"   #include "program.h"   #include "language.h"
710:    emit2(F_MARK);    do_docode(CDR(n),0);    tmp1=store_constant(& CAR(n)->u.sval, -  !(CAR(n)->tree_info & OPT_EXTERNAL_DEPEND)); +  !(CAR(n)->tree_info & OPT_EXTERNAL_DEPEND), +  CAR(n)->name);    emit(F_APPLY,tmp1);    }    if(n->type == void_type_string)
731:    emit2(F_MARK);    do_docode(CDR(n),0);    tmp1=store_constant(& CAR(n)->u.sval, -  !(CAR(n)->tree_info & OPT_EXTERNAL_DEPEND)); +  !(CAR(n)->tree_info & OPT_EXTERNAL_DEPEND), +  CAR(n)->name);    emit(F_APPLY,tmp1);       return 1;
767:    {    emit2(F_CALL_FUNCTION);    }else{ -  tmp1=store_constant(& foo->u.sval, 1); +  /* We might want to put "predef::"+foo->name here /Hubbe */ +  tmp1=store_constant(& foo->u.sval, 1, foo->name);    emit(F_APPLY, tmp1);    }    }
872:    for(e=1; e<cases*2+2; e++)    update_arg(jumptable[e], current_switch_jumptable[e]);    -  update_arg(tmp1, store_constant(sp-1,1)); +  update_arg(tmp1, store_constant(sp-1,1,0));       pop_stack();    free((char *)jumptable);
1138:   #endif       default: -  tmp1=store_constant(&(n->u.sval),!(n->tree_info & OPT_EXTERNAL_DEPEND)); +  tmp1=store_constant(&(n->u.sval), +  !(n->tree_info & OPT_EXTERNAL_DEPEND), +  n->name);    emit(F_CONSTANT,tmp1);    return 1;       case T_ARRAY:    case T_MAPPING:    case T_MULTISET: -  tmp1=store_constant(&(n->u.sval),!(n->tree_info & OPT_EXTERNAL_DEPEND)); +  tmp1=store_constant(&(n->u.sval), +  !(n->tree_info & OPT_EXTERNAL_DEPEND), +  n->name);    emit(F_CONSTANT,tmp1);       /* copy now or later ? */