pike.git / src / opcodes.c

version» Context lines:

pike.git/src/opcodes.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: opcodes.c,v 1.131 2003/01/09 15:21:27 grubba Exp $ + || $Id: opcodes.c,v 1.132 2003/01/14 11:54:06 jhs Exp $   */      #include "global.h"   #include <errno.h>   #include <math.h>   #include <ctype.h>   #include "interpret.h"   #include "svalue.h"   #include "array.h"   #include "stralloc.h"
pike.git/src/opcodes.c:23:   #include "fd_control.h"   #include "cyclic.h"   #include "builtin_functions.h"   #include "module_support.h"   #include "security.h"   #include "bignum.h"   #include "operators.h"      #define sp Pike_sp    - RCSID("$Id: opcodes.c,v 1.131 2003/01/09 15:21:27 grubba Exp $"); + RCSID("$Id: opcodes.c,v 1.132 2003/01/14 11:54:06 jhs Exp $");      void index_no_free(struct svalue *to,struct svalue *what,struct svalue *ind)   {    INT32 i;      #ifdef PIKE_SECURITY    if(what->type <= MAX_COMPLEX)    if(!CHECK_DATA_SECURITY(what->u.array, SECURITY_BIT_INDEX))    Pike_error("Index permission denied.\n");   #endif
pike.git/src/opcodes.c:1790:   MK_VERY_LOW_SSCANF(0,2)      #undef CHAROPT2   #define CHAROPT2(X) X      MK_VERY_LOW_SSCANF(1,1)   MK_VERY_LOW_SSCANF(2,1)   MK_VERY_LOW_SSCANF(1,2)   MK_VERY_LOW_SSCANF(2,2)    + /*! @decl int sscanf(string data, string format, mixed ... lvalues) +  *! +  *! The purpose of sscanf is to match one string against a format string and +  *! place the matching results into a list of variables. The list of @[lvalues] +  *! are destructively modified (which is only possible because sscanf really is +  *! an opcode, rather than a pike function) with the values extracted from the +  *! @[data] according to the @[format] specification. Only the variables up to +  *! the last matching directive of the format string are touched. +  *! +  *! Refer to the @[chapter::sscanf] chapter for the complete list of directives +  *! sscanf understands. +  *! +  *! @returns +  *! The number of directives matched in the format string. Note that a string +  *! directive (%s or %[]) always counts as a match, even when matching the +  *! empty string. +  *! @seealso +  *! @[array_sscanf()], @[chapter::sscanf] +  */   void o_sscanf(INT32 args)   {    INT32 i=0;    int x;    ptrdiff_t matched_chars;    struct svalue *save_sp=sp;       if(sp[-args].type != T_STRING)    SIMPLE_BAD_ARG_ERROR("sscanf", 1, "string");