diff options
author | Lars Knoll <lars.knoll@digia.com> | 2013-04-05 14:37:24 +0200 |
---|---|---|
committer | Simon Hausmann <simon.hausmann@digia.com> | 2013-04-05 16:08:49 +0200 |
commit | e6262c49f36618197817123b76a5ab32361c3596 (patch) | |
tree | c2a604ba5620b6b0462bbbee6d55f9d3da5a9c22 | |
parent | 58d6fc71544343ffd9bbefcfb49eca16e0ae660a (diff) |
Remove unused methods
Change-Id: I928b9c4816b421e3d79bd038c37e24d09129899d
Reviewed-by: Simon Hausmann <simon.hausmann@digia.com>
-rw-r--r-- | src/v4/qv4context.cpp | 36 | ||||
-rw-r--r-- | src/v4/qv4context.h | 2 |
2 files changed, 0 insertions, 38 deletions
diff --git a/src/v4/qv4context.cpp b/src/v4/qv4context.cpp index 274b2eb6..c34dcc00 100644 --- a/src/v4/qv4context.cpp +++ b/src/v4/qv4context.cpp @@ -100,7 +100,6 @@ bool ExecutionContext::setMutableBinding(ExecutionContext *scope, String *name, // ### throw if scope->strict is true, and it would change an immutable binding if (type == Type_CallContext) { CallContext *c = static_cast<CallContext *>(this); - assert(function); for (unsigned int i = 0; i < c->function->varCount; ++i) if (c->function->varList[i]->isEqualTo(name)) { c->locals[i] = value; @@ -121,41 +120,6 @@ bool ExecutionContext::setMutableBinding(ExecutionContext *scope, String *name, return false; } -Value ExecutionContext::getBindingValue(ExecutionContext *scope, String *name, bool strict) const -{ - Q_UNUSED(strict); - assert(function); - - if (type == Type_CallContext) { - assert(function); - const CallContext *c = static_cast<const CallContext *>(this); - for (unsigned int i = 0; i < function->varCount; ++i) - if (c->function->varList[i]->isEqualTo(name)) - return c->locals[i]; - for (int i = (int)c->function->formalParameterCount - 1; i >= 0; --i) - if (c->function->formalParameterList[i]->isEqualTo(name)) - return c->arguments[i]; - } - - if (activation) { - bool hasProperty = false; - Value v = activation->get(scope, name, &hasProperty); - if (hasProperty) - return v; - } - assert(false); -} - -bool ExecutionContext::deleteBinding(ExecutionContext *scope, String *name) -{ - if (activation) - activation->deleteProperty(scope, name); - - if (scope->strictMode) - scope->throwTypeError(); - return false; -} - String * const *ExecutionContext::formals() const { return type == Type_CallContext ? static_cast<const CallContext *>(this)->function->formalParameterList : 0; diff --git a/src/v4/qv4context.h b/src/v4/qv4context.h index a1da174c..ff375fea 100644 --- a/src/v4/qv4context.h +++ b/src/v4/qv4context.h @@ -110,8 +110,6 @@ struct ExecutionContext void createMutableBinding(String *name, bool deletable); bool setMutableBinding(ExecutionContext *scope, String *name, const Value &value); - Value getBindingValue(ExecutionContext *scope, String *name, bool strict) const; - bool deleteBinding(ExecutionContext *ctx, String *name); void wireUpPrototype(); |