--- parser3/src/include/Attic/pa_vmframe.h 2001/02/25 08:12:21 1.2 +++ parser3/src/include/Attic/pa_vmframe.h 2001/02/25 17:33:43 1.7 @@ -1,5 +1,5 @@ /* - $Id: pa_vmframe.h,v 1.2 2001/02/25 08:12:21 paf Exp $ + $Id: pa_vmframe.h,v 1.7 2001/02/25 17:33:43 paf Exp $ */ #ifndef PA_VMFRAME_H @@ -23,16 +23,21 @@ public: // Value } // frame: my or self_transparent void put_element(const String& name, Value *value){ - if(!my.replace(name, value)) + if(!my.put_replace(name, value)) self->put_element(name, value); } - // frame: none yet | transparent - VClass *get_class() const { return self->get_class(); } + // frame: self_transparent + VClass* get_class() { return self->get_class(); } + + // methodframe: self + Value *get_aliased() { return self; } public: // usage - VMethodFrame(Pool& apool, const Junction& ajunction) : WContext(apool, 0 /* empty */), + VMethodFrame(Pool& apool, const Junction& ajunction) : + WContext(apool, 0 /* empty */, false /* not constructing */), + junction(ajunction), store_param_index(0), my(apool), @@ -48,13 +53,13 @@ public: // usage } } - void set_self(Value *aself) { self=aself; } + void set_self(Value& aself) { self=&aself; } void store_param(Value *value) { Method *method=junction.method; if(store_param_index==method->params_names.size()) THROW(0,0, - name(), + &name(), "call: too many params (max=%d)", method->params_names.size()); my.put(*static_cast(method->params_names.get(store_param_index++)), value);