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

Unified Diff: src/transitions.cc

Issue 10784014: Removed transitions from the accessor pair descriptors. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Addressed comments Created 8 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
« no previous file with comments | « src/transitions.h ('k') | src/transitions-inl.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/transitions.cc
diff --git a/src/transitions.cc b/src/transitions.cc
index 1e965cda716af594d198ab118a01a72bd4a78da8..f2e49ecafec3af954a24602e42a85f5f2f1a7707 100644
--- a/src/transitions.cc
+++ b/src/transitions.cc
@@ -54,10 +54,10 @@ void TransitionArray::CopyFrom(TransitionArray* origin,
int origin_transition,
int target_transition,
const WhitenessWitness& witness) {
- this->Set(target_transition,
- origin->GetKey(origin_transition),
- origin->GetValue(origin_transition),
- witness);
+ Set(target_transition,
+ origin->GetKey(origin_transition),
+ origin->GetTarget(origin_transition),
+ witness);
}
@@ -66,7 +66,7 @@ static bool InsertionPointFound(String* key1, String* key2) {
}
-MaybeObject* TransitionArray::NewWith(String* name, Object* value) {
+MaybeObject* TransitionArray::NewWith(String* name, Map* target) {
TransitionArray* result;
{ MaybeObject* maybe_array;
@@ -76,12 +76,12 @@ MaybeObject* TransitionArray::NewWith(String* name, Object* value) {
FixedArray::WhitenessWitness witness(result);
- result->Set(0, name, value, witness);
+ result->Set(0, name, target, witness);
return result;
}
-MaybeObject* TransitionArray::CopyInsert(String* name, Object* value) {
+MaybeObject* TransitionArray::CopyInsert(String* name, Map* target) {
TransitionArray* result;
int number_of_transitions = this->number_of_transitions();
@@ -90,10 +90,9 @@ MaybeObject* TransitionArray::CopyInsert(String* name, Object* value) {
int insertion_index = this->Search(name);
if (insertion_index == kNotFound) ++new_size;
- { MaybeObject* maybe_array;
- maybe_array = TransitionArray::Allocate(new_size);
- if (!maybe_array->To(&result)) return maybe_array;
- }
+ MaybeObject* maybe_array;
+ maybe_array = TransitionArray::Allocate(new_size);
+ if (!maybe_array->To(&result)) return maybe_array;
if (HasElementsTransition()) {
result->set_elements_transition(elements_transition());
@@ -109,7 +108,7 @@ MaybeObject* TransitionArray::CopyInsert(String* name, Object* value) {
for (int i = 0; i < number_of_transitions; ++i) {
if (i != insertion_index) result->CopyFrom(this, i, i, witness);
}
- result->Set(insertion_index, name, value, witness);
+ result->Set(insertion_index, name, target, witness);
return result;
}
@@ -119,7 +118,7 @@ MaybeObject* TransitionArray::CopyInsert(String* name, Object* value) {
result->CopyFrom(this, insertion_index, insertion_index, witness);
}
- result->Set(insertion_index, name, value, witness);
+ result->Set(insertion_index, name, target, witness);
for (; insertion_index < number_of_transitions; ++insertion_index) {
result->CopyFrom(this, insertion_index, insertion_index + 1, witness);
« no previous file with comments | « src/transitions.h ('k') | src/transitions-inl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698