|
|
| version 1.18, 2001/02/23 11:39:57 | version 1.20, 2001/02/23 18:12:44 |
|---|---|
| Line 33 public: | Line 33 public: |
| Array& aparams_names, | Array& aparams_names, |
| Array& alocals_names, | Array& alocals_names, |
| Array& acode) : | Array& acode) : |
| Pooled(apool), | Pooled(apool), |
| name(aname), | name(aname), |
| params_names(aparams_names), | params_names(aparams_names), |
| Line 48 class Operator : public Method { | Line 49 class Operator : public Method { |
| }; | }; |
| */ | */ |
| class Method_ref { | class Junction : Pooled { |
| public: | public: |
| Value *self; | |
| Method& method; | |
| }; | |
| class Junction { | Junction(Pool& apool, |
| bool auto_calc; | Method *amethod, |
| Value& root; | Value *aroot, |
| Value *self; | Value *aself, |
| Value& rcontext; | Value *arcontext, |
| WContext& wcontext; | Array *acode) : Pooled(apool), |
| Array& code; | |
| method(amethod), | |
| root(aroot), | |
| self(aself), | |
| rcontext(arcontext), | |
| code(acode) { | |
| } | |
| const Method *method; | |
| const Value *root; | |
| const Value *self; | |
| const Value *rcontext; | |
| const Array *code; | |
| }; | }; |
| class Value : public Pooled { | class Value : public Pooled { |
| Line 78 public: // Value | Line 88 public: // Value |
| // string: value | // string: value |
| virtual void put_string(String *astring) { failed("storing string to %s"); } | virtual void put_string(String *astring) { failed("storing string to %s"); } |
| // method_ref: self, method | |
| virtual Method_ref *get_method_ref() { failed("extracting method reference from %s"); return 0; } | |
| // junction: auto_calc,root,self,rcontext,wcontext, code | // junction: auto_calc,root,self,rcontext,wcontext, code |
| virtual Junction *get_junction() { failed("getting junction from %s"); return 0; } | virtual Junction *get_junction() { failed("getting junction from %s"); return 0; } |
| Line 88 public: // Value | Line 95 public: // Value |
| // object_class: (field)=STATIC.value;(STATIC)=hash;(method)=method_ref with self=object_class | // object_class: (field)=STATIC.value;(STATIC)=hash;(method)=method_ref with self=object_class |
| // object_instance: (field)=value;(STATIC)=hash;(method)=method_ref | // object_instance: (field)=value;(STATIC)=hash;(method)=method_ref |
| // operator_class: (field)=value - static values only | // operator_class: (field)=value - static values only |
| // wcontext: transparent | |
| // frame: my or self_transparent | |
| virtual Value *get_element(const String& name) { failed("getting element from %s"); return 0; } | virtual Value *get_element(const String& name) { failed("getting element from %s"); return 0; } |
| // hash: (key)=value | // hash: (key)=value |
| // object_class, operator_class: (field)=value - static values only | // object_class, operator_class: (field)=value - static values only |
| // wcontext: transparent | |
| // frame: my or self_transparent | |
| virtual void put_element(const String& name, Value *value) { failed("putting element to %s"); } | virtual void put_element(const String& name, Value *value) { failed("putting element to %s"); } |
| // object_instance, object_class: method | |
| virtual Method *get_method(const String& name) const { return 0; } | |
| // object_class, object_instance: object_class | // object_class, object_instance: object_class |
| // frame: transparent | |
| // wcontext: transparent | |
| virtual VClass *get_class() { return 0; } | virtual VClass *get_class() { return 0; } |
| // object_class: true when this class is this or derived from 'ancestor' | // object_class: true when this class is this or derived from 'ancestor' |
| // frame: transparent | |
| // wcontext: transparent | |
| virtual bool is_or_derived_from(VClass& ancestor) { failed("thoghts of ancestors of %s"); return false; } | virtual bool is_or_derived_from(VClass& ancestor) { failed("thoghts of ancestors of %s"); return false; } |
| public: // usage | public: // usage |