pike.git / src / operators.c

version» Context lines:

pike.git/src/operators.c:488:    {    struct object *o = sp[-1].u.object;    int f = FIND_LFUN(o->prog->inherits[SUBTYPEOF(sp[-1])].prog, LFUN_CAST);    if(f == -1) {    if (run_time_type != T_PROGRAM) {    Pike_error("No cast method in object.\n");    }    f_object_program(1);    return;    } -  push_text(get_name_of_type(type->type)); +  push_static_text(get_name_of_type(type->type));    apply_low(o, f, 1);       if (run_time_type == T_PROGRAM) {    if (IS_UNDEFINED(Pike_sp-1)) {    pop_stack();    f_object_program(1);    return;    }    }   
pike.git/src/operators.c:725:    {    switch(TYPEOF(sp[-1])) {    case T_OBJECT:    if(sp[-1].u.object->prog)    {    struct object *o = sp[-1].u.object;    int f = FIND_LFUN(o->prog->inherits[SUBTYPEOF(sp[-1])].prog,    LFUN__IS_TYPE);    if( f != -1)    { -  push_text(get_name_of_type(run_time_type)); +  push_static_text(get_name_of_type(run_time_type));    apply_low(o, f, 1);    f=!UNSAFE_IS_ZERO(sp-1);    pop_stack();    if(f) goto emulated_type_ok;    }    }    break;    case T_FUNCTION:    /* Check that the function actually is a program. */    if ((run_time_type == T_PROGRAM) &&
pike.git/src/operators.c:1037:    int lfun;    if (!s->u.object->prog) return 0;    if (type->type == PIKE_T_FUNCTION) {    if ((lfun = FIND_LFUN(s->u.object->prog, LFUN_CALL)) != -1) {    /* FIXME: Add code here. */    return 1;    }    }    if ((lfun = FIND_LFUN(s->u.object->prog, LFUN__IS_TYPE)) != -1) {    int ret; -  push_text(get_name_of_type(type->type)); +  push_static_text(get_name_of_type(type->type));    apply_low(s->u.object, lfun, 1);    ret = !UNSAFE_IS_ZERO(Pike_sp-1);    pop_stack();    return ret;    }    return 0;    }    if ((TYPEOF(*s) == PIKE_T_FUNCTION) && (type->type == PIKE_T_PROGRAM)) {    /* FIXME: Add code here. */    return 1;