pike.git / src / program.c

version» Context lines:

pike.git/src/program.c:6737:      PMOD_EXPORT int low_find_lfun(struct program *p, ptrdiff_t lfun)   {    struct pike_string *lfun_name;    unsigned int flags = 0;    int i;   #if 0    struct identifier *id;   #endif    if ((size_t)lfun >= NELEM(lfun_strings)) { -  return -1; +  return find_lfun_fatal(p, lfun);    }       lfun_name = lfun_strings[lfun];       i = really_low_find_shared_string_identifier(lfun_name,    dmalloc_touch(struct program *,    p),    SEE_PROTECTED);   #if 0    if (i < 0 || !(p->flags & PROGRAM_FIXED)) return i;    id = ID_FROM_INT(p, i);    if (IDENTIFIER_IS_PIKE_FUNCTION(id->identifier_flags) &&    (id->func.offset == -1)) {    /* Function prototype. */    return -1;    }   #endif /* 0 */    return i;   }    -  + PMOD_EXPORT int find_lfun_fatal(struct program *p, ptrdiff_t lfun) + { +  Pike_fatal("Invalid lfun number: %d\n", lfun); +  return -1; + } +    int lfun_lookup_id(struct pike_string *lfun_name)   {    struct svalue *id = low_mapping_string_lookup(lfun_ids, lfun_name);    if (!id) return -1;    if (TYPEOF(*id) == T_INT) return id->u.integer;    my_yyerror("Bad entry in lfun lookup table for %S.", lfun_name);    return -1;   }      /*