pike.git / src / builtin_functions.c

version» Context lines:

pike.git/src/builtin_functions.c:1:   /*   || This file is part of Pike. For copyright information see COPYRIGHT.   || Pike is distributed under GPL, LGPL and MPL. See the file COPYING   || for more information. - || $Id: builtin_functions.c,v 1.619 2007/01/03 23:10:45 peter Exp $ + || $Id: builtin_functions.c,v 1.620 2007/01/15 15:44:00 grubba Exp $   */      #include "global.h"   #include "interpret.h"   #include "svalue.h"   #include "pike_macros.h"   #include "object.h"   #include "program.h"   #include "array.h"   #include "pike_error.h"
pike.git/src/builtin_functions.c:161:    /* Splice operator. */    add_args = copy_node(CAR(args));    } else {    new_args = copy_node(args);    count = 1;    }    args = args->parent;    }       for(; args; args = args->parent) { +  if (!CDR(args)) continue;    if (CDR(args)->token == F_PUSH_ARRAY) {    if (count) {    add_args = mknode(F_ARG_LIST, add_args,    mkapplynode(copy_node(CAR(n)), new_args));    new_args = NULL;    count = 0;    }    add_args = mknode(F_ARG_LIST, add_args, copy_node(CADR(args)));    } else {    new_args = mknode(F_ARG_LIST, new_args, copy_node(CDR(args)));
pike.git/src/builtin_functions.c:808:    *! and the iterator index will be returned. If @[needle] is not    *! found, @[haystack] will be advanced to the end (and will thus    *! evaluate to false), and a zero with zero_type 1 will be returned.    *! @endmixed    *!    *! @note    *! If @[start] is supplied to an iterator object without an    *! @[lfun::_search()], @[haystack] will need to implement    *! @[Iterator()->set_index()].    *! +  *! @note +  *! For mappings and object @[UNDEFINED] will be returned when not found. +  *! In all other cases @expr{-1@} will be returned when not found. +  *!    *! @seealso    *! @[indices()], @[values()], @[zero_type()]    */   PMOD_EXPORT void f_search(INT32 args)   {    ptrdiff_t start;       if(args < 2)    SIMPLE_TOO_FEW_ARGS_ERROR("search", 2);