pike.git / src / builtin.cmod

version» Context lines:

pike.git/src/builtin.cmod:1:   /* -*- c -*-   || 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.cmod,v 1.219 2008/06/29 18:01:39 nilsson Exp $ + || $Id: builtin.cmod,v 1.220 2008/06/29 23:14:18 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.cmod:644:       RETURN mkmapping(ind, val);   }      /*! @decl void secure(string str)    *! @belongs String    *!    *! Marks the string as secure, which will clear the memory area    *! before freeing the string.    */ - PIKEFUN string secure(string str) + PIKEFUN string string_secure(string str)    optflags OPT_SIDE_EFFECT; -  +  rawtype tFunc(tSetvar(0, tStr), tVar(0));   {    str->flags |= STRING_CLEAR_ON_EXIT;    RETURN str;   }      /*! @decl int count(string haystack, string needle)    *! @belongs String    *!    *! Count the number of non-overlapping times the string @[needle]    *! occurs in the string @[haystack]. The special cases for the needle
pike.git/src/builtin.cmod:3698:    pop_n_elems(args);    if (THIS->cur->next && THIS->cur->prev) {    push_svalue(&THIS->cur->val);    } else {    push_undefined();    }    }       /*! @decl int(0..1) first()    *! -  *! Reset the iterator. +  *! Reset the iterator to point to the first element in +  *! the list.    *!    *! @returns    *! Returns @expr{1@} if there are elements in the list,    *! and @expr{0@} (zero) if the list is empty.    */    PIKEFUN int(0..1) first()    {    struct external_variable_context loc;    struct List_struct *parent;    pop_n_elems(args);