Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(832)

Unified Diff: src/scopes.cc

Issue 7399023: Pass isolate to AST ID functions. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« src/parser.cc ('K') | « src/rewriter.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/scopes.cc
diff --git a/src/scopes.cc b/src/scopes.cc
index f25f5a359325d29c6f5a5a43b50128bca342a4f6..2da5f6b94166b531c980e6eb0df3f2201e0e1244 100644
--- a/src/scopes.cc
+++ b/src/scopes.cc
@@ -304,7 +304,8 @@ void Scope::Initialize(bool inside_with) {
Variable::VAR,
false,
Variable::THIS);
- var->set_rewrite(new(isolate_->zone()) Slot(var, Slot::PARAMETER, -1));
+ var->set_rewrite(new(isolate_->zone()) Slot(
+ isolate_, var, Slot::PARAMETER, -1));
receiver_ = var;
}
@@ -350,7 +351,8 @@ Variable* Scope::LocalLookup(Handle<String> name) {
Variable* var =
variables_.Declare(this, name, mode, true, Variable::NORMAL);
- var->set_rewrite(new(isolate_->zone()) Slot(var, Slot::CONTEXT, index));
+ var->set_rewrite(
+ new(isolate_->zone()) Slot(isolate_, var, Slot::CONTEXT, index));
return var;
}
@@ -407,8 +409,8 @@ VariableProxy* Scope::NewUnresolved(Handle<String> name,
// the same name because they may be removed selectively via
// RemoveUnresolved().
ASSERT(!already_resolved());
- VariableProxy* proxy =
- new(isolate_->zone()) VariableProxy(name, false, inside_with, position);
+ VariableProxy* proxy = new(isolate_->zone()) VariableProxy(
+ isolate_, name, false, inside_with, position);
unresolved_.Add(proxy);
return proxy;
}
@@ -708,7 +710,8 @@ Variable* Scope::NonLocal(Handle<String> name, Variable::Mode mode) {
// Declare a new non-local.
var = map->Declare(NULL, name, mode, true, Variable::NORMAL);
// Allocate it by giving it a dynamic lookup.
- var->set_rewrite(new(isolate_->zone()) Slot(var, Slot::LOOKUP, -1));
+ var->set_rewrite(
+ new(isolate_->zone()) Slot(isolate_, var, Slot::LOOKUP, -1));
}
return var;
}
@@ -964,14 +967,14 @@ bool Scope::HasArgumentsParameter() {
void Scope::AllocateStackSlot(Variable* var) {
- var->set_rewrite(
- new(isolate_->zone()) Slot(var, Slot::LOCAL, num_stack_slots_++));
+ var->set_rewrite(new(isolate_->zone()) Slot(
+ isolate_, var, Slot::LOCAL, num_stack_slots_++));
}
void Scope::AllocateHeapSlot(Variable* var) {
- var->set_rewrite(
- new(isolate_->zone()) Slot(var, Slot::CONTEXT, num_heap_slots_++));
+ var->set_rewrite(new(isolate_->zone()) Slot(
+ isolate_, var, Slot::CONTEXT, num_heap_slots_++));
}
@@ -1024,7 +1027,8 @@ void Scope::AllocateParameterLocals() {
} else {
ASSERT(var->rewrite() == NULL || var->IsParameter());
if (var->rewrite() == NULL) {
- var->set_rewrite(new(isolate_->zone()) Slot(var, Slot::PARAMETER, i));
+ var->set_rewrite(
+ new(isolate_->zone()) Slot(isolate_, var, Slot::PARAMETER, i));
}
}
}
« src/parser.cc ('K') | « src/rewriter.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698