Branch: Tag:

1999-12-14

1999-12-14 08:38:07 by Fredrik Hübinette (Hubbe) <hubbe@hubbe.net>

fix in type for search()

Rev: src/builtin_functions.c:1.224

5:   \*/   /**/   #include "global.h" - RCSID("$Id: builtin_functions.c,v 1.223 1999/12/12 22:41:33 per Exp $"); + RCSID("$Id: builtin_functions.c,v 1.224 1999/12/14 08:38:07 hubbe Exp $");   #include "interpret.h"   #include "svalue.h"   #include "pike_macros.h"
5558:       /* FIXME: Is the third arg a good idea when the first is a mapping? */    ADD_EFUN("search",f_search, -  tOr3(tFunc(tStr tStr tOr(tVoid,tInt), +  tOr4(tFunc(tStr tStr tOr(tVoid,tInt),    tInt),    tFunc(tArr(tSetvar(0,tMix)) tVar(0) tOr(tVoid,tInt),    tInt),    tFunc(tMap(tSetvar(1,tMix),tSetvar(2,tMix)) tVar(2) tOr(tVoid,tVar(1)), -  tVar(1))), +  tVar(1)), +  +  tIfnot( +  tFunc(tArr(tSetvar(0,tMix)) tVar(0) tOr(tVoid,tInt), +  tInt), +  tIfnot( +  tFunc(tMap(tSetvar(1,tMix),tSetvar(2,tMix)) tVar(2) tOr(tVoid,tVar(1)), +  tVar(1)), +  tFunc( tOr(tMapping,tArray) tMix tOr(tVoid,tMix), tZero)))),    0);      /* function(float|int,int|void:void) */