pike.git / src / error.c

version» Context lines:

pike.git/src/error.c:13:   #include "array.h"   #include "object.h"   #include "main.h"   #include "builtin_functions.h"   #include "backend.h"   #include "operators.h"   #include "module_support.h"   #include "threads.h"   #include "gc.h"    - RCSID("$Id: error.c,v 1.50 2000/04/19 21:26:19 mast Exp $"); + RCSID("$Id: error.c,v 1.51 2000/05/25 02:18:35 hubbe Exp $");      #undef ATTRIBUTE   #define ATTRIBUTE(X)      JMP_BUF *recoveries=0;      #ifdef PIKE_DEBUG   void check_recovery_context(void)   {    char foo;
pike.git/src/error.c:545:    struct svalue *base_sp, int args,    char *permission_type,    char *desc, ...) ATTRIBUTE((noreturn, format(printf, 5, 6)))   {    INIT_ERROR(permission);    ERROR_STRUCT(permission,o)->permission_type=    make_shared_string(permission_type);    ERROR_DONE(generic);   }    + void wrong_number_of_args_error(char *name, int args, int expected) + { +  char *msg; +  if(expected>args) +  { +  msg="Too few arguments"; +  }else{ +  msg="Too many arguments"; +  } +  +  new_error(name, msg, sp-args, args, 0,0); + } +    #ifdef PIKE_DEBUG   static void gc_check_throw_value(struct callback *foo, void *bar, void *gazonk)   {    debug_gc_xmark_svalues(&throw_value,1," in the throw value");   }   #endif      void init_error(void)   {   #define ERR_SETUP