pike.git / src / interpret.c

version» Context lines:

pike.git/src/interpret.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: interpret.c,v 1.395 2008/04/14 16:33:32 grubba Exp $ + || $Id: interpret.c,v 1.396 2008/05/10 11:53:41 grubba Exp $   */      #include "global.h"   #include "interpret.h"   #include "object.h"   #include "program.h"   #include "svalue.h"   #include "array.h"   #include "mapping.h"   #include "pike_error.h"
pike.git/src/interpret.c:1884:    if(Pike_interpreter.trace_level)    {    dynamic_buffer save_buf;    init_buf(&save_buf);    safe_describe_svalue(s,0,0);    do_trace_call(args, &save_buf);    }    apply_array(s->u.array,args);    break;    +  case PIKE_T_TYPE: +  if (args != 1) { +  /* FIXME: Casts to object ought to propagate to apply program below. */ +  SIMPLE_WRONG_NUM_ARGS_ERROR("cast", 1); +  } +  o_cast(s->u.type, compile_type_to_runtime_type(s->u.type)); +  break; +     case T_PROGRAM:    if(Pike_interpreter.trace_level)    {    dynamic_buffer save_buf;    init_buf(&save_buf);    safe_describe_svalue(s,0,0);    do_trace_call(args, &save_buf);    }    push_object(clone_object(s->u.program,args));    break;