pike.git / src / opcodes.c

version» Context lines:

pike.git/src/opcodes.c:1:   /*\   ||| This file a part of Pike, and is copyright by Fredrik Hubinette   ||| Pike is distributed as GPL (General Public License)   ||| See the files COPYING and DISCLAIMER for more information.   \*/ + /**/   #include "global.h"   #include <math.h>   #include <ctype.h>   #include "interpret.h"   #include "svalue.h"   #include "array.h"   #include "stralloc.h"   #include "mapping.h"   #include "multiset.h"   #include "opcodes.h"
pike.git/src/opcodes.c:171:    }       case T_OBJECT:    switch(sp[-1].type)    {    case T_STRING:    APPLY_MASTER("cast_to_object",1);    break;       case T_FUNCTION: +  if (sp[-1].subtype == FUNCTION_BUILTIN) { +  error("Cannot cast builtin functions to object.\n"); +  } else {    sp[-1].type = T_OBJECT; -  +  }    break;    }    break;       case T_PROGRAM:    APPLY_MASTER("cast_to_program",1);    break;       case T_FUNCTION:    {