diff options
author | Christian Kamm <[email protected]> | 2010-02-03 10:59:52 +0100 |
---|---|---|
committer | Christian Kamm <[email protected]> | 2010-02-03 10:59:52 +0100 |
commit | 49c43aaab152ba4e885f53e2b38720c3704a135d (patch) | |
tree | 91aa2acba74579f7e088a28beaf260ea3efe9606 /src/libs/qmljs/qmljsinterpreter.cpp | |
parent | ba18e7003421562b698d064998b8eecf1f92c4a1 (diff) |
Get rid of Environment, introduce external ScopeChain in Link.
Done-with: Roberto
Diffstat (limited to 'src/libs/qmljs/qmljsinterpreter.cpp')
-rw-r--r-- | src/libs/qmljs/qmljsinterpreter.cpp | 51 |
1 files changed, 1 insertions, 50 deletions
diff --git a/src/libs/qmljs/qmljsinterpreter.cpp b/src/libs/qmljs/qmljsinterpreter.cpp index b248fd2f94d..6d293ac5e37 100644 --- a/src/libs/qmljs/qmljsinterpreter.cpp +++ b/src/libs/qmljs/qmljsinterpreter.cpp @@ -623,39 +623,6 @@ const Reference *Value::asReference() const } //////////////////////////////////////////////////////////////////////////////// -// Environment -//////////////////////////////////////////////////////////////////////////////// -Environment::Environment() -{ -} - -Environment::~Environment() -{ -} - -const Environment *Environment::parent() const -{ - return 0; -} - -const Value *Environment::lookup(const QString &name) const -{ - if (const Value *member = lookupMember(name)) - return member; - - else if (const Environment *p = parent()) - return p->lookup(name); - - else - return 0; -} - -const Value *Environment::lookupMember(const QString &) const -{ - return 0; -} - -//////////////////////////////////////////////////////////////////////////////// // Values //////////////////////////////////////////////////////////////////////////////// const NullValue *NullValue::asNullValue() const @@ -788,8 +755,7 @@ bool MemberProcessor::processGeneratedSlot(const QString &, const Value *) ObjectValue::ObjectValue(Engine *engine) : _engine(engine), - _prototype(0), - _scope(0) + _prototype(0) { engine->registerObject(this); } @@ -818,16 +784,6 @@ const ObjectValue *ObjectValue::prototype() const return _prototype; } -const ObjectValue *ObjectValue::scope() const -{ - return _scope; -} - -void ObjectValue::setScope(const ObjectValue *scope) -{ - _scope = scope; -} - void ObjectValue::setProperty(const QString &name, const Value *value) { _members[name] = value; @@ -893,11 +849,6 @@ void ObjectValue::processMembers(MemberProcessor *processor) const } } -const Environment *ObjectValue::parent() const -{ - return _scope; -} - const Value *ObjectValue::lookupMember(const QString &name) const { if (const Value *m = _members.value(name)) |