pike.git
/
src
/
program.c
version
»
Context lines:
10
20
40
80
file
none
3
pike.git/src/program.c:212:
"_m_delete", "_get_iterator", "`[..]", /* NOTE: After this point there are only fake lfuns. */ "_search", "_types", "_serialize", "_deserialize", "_size_object", "_random",
+
"pow",
}; struct pike_string *lfun_strings[NELEM(lfun_names)]; static struct mapping *lfun_ids; /* mapping(string:type) */ static struct mapping *lfun_types; static const char *const raw_lfun_types[] = {
pike.git/src/program.c:274:
tFuncV(tZero,tVoid,tMix), /* "_m_delete", */ tFuncV(tNone,tVoid,tObj), /* "_get_iterator", */ tFuncV(tZero tRangeBound tZero tRangeBound, tVoid, tMix), /* "`[..]" */ /* NOTE: After this point there are only fake lfuns. */ tFuncV(tZero tOr(tZero, tVoid), tVoid, tMix), /* "_search", */ tFuncV(tNone,tVoid,tArray), /* "_types", */ tFuncV(tObj tZero, tVoid, tVoid), /* "_serialize", */ tFuncV(tObj tZero, tVoid, tVoid), /* "_deserialize", */ tFuncV(tZero, tVoid, tInt), /* "_size_object", */ tFuncV(tFunction tFunction, tVoid, tMix), /* "_random", */
+
tFuncV(tOr3(tInt,tFloat,tObj),tVoid,tOr3(tObj,tInt,tFloat)), /* "pow", */
}; /* These two are not true LFUNs! */ static struct pike_type *lfun_getter_type_string = NULL; static struct pike_type *lfun_setter_type_string = NULL; /*! @namespace lfun:: *! *! Callback functions used to overload various builtin functions. *!
pike.git/src/program.c:7039:
Pike_error("Too many arguments to %S().\n", name); } } PMOD_EXPORT int low_find_lfun(struct program *p, ptrdiff_t lfun) { struct pike_string *lfun_name; unsigned int flags = 0; int i; struct identifier *id;
+
#ifdef PIKE_DEBUG
if ((size_t)lfun >= NELEM(lfun_strings)) { return find_lfun_fatal(p, lfun); }
-
+
#endif
lfun_name = lfun_strings[lfun]; i = really_low_find_shared_string_identifier(lfun_name, dmalloc_touch(struct program *, p), SEE_PROTECTED); 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)) {