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

Unified Diff: src/objects.cc

Issue 11365221: Allow property indexes to refer to slots inside the object header. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 8 years, 1 month 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/mips/stub-cache-mips.cc ('k') | src/property.h » ('j') | src/property.h » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index fa5bfeda82ca831640d5aabff6b956de8c70477b..d4abd9456d67b66614e8ba59d4d5b0d8f1865e3c 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -641,7 +641,8 @@ MaybeObject* Object::GetProperty(Object* receiver,
ASSERT(!value->IsTheHole() || result->IsReadOnly());
return value->IsTheHole() ? heap->undefined_value() : value;
case FIELD:
- value = result->holder()->FastPropertyAt(result->GetFieldIndex());
+ value = result->holder()->FastPropertyAt(
+ result->GetFieldIndex().FieldIndex());
ASSERT(!value->IsTheHole() || result->IsReadOnly());
return value->IsTheHole() ? heap->undefined_value() : value;
case CONSTANT_FUNCTION:
@@ -2436,7 +2437,7 @@ void JSObject::LocalLookupRealNamedProperty(String* name,
// occur as fields.
if (result->IsField() &&
result->IsReadOnly() &&
- FastPropertyAt(result->GetFieldIndex())->IsTheHole()) {
+ FastPropertyAt(result->GetFieldIndex().FieldIndex())->IsTheHole()) {
result->DisallowCaching();
}
return;
@@ -2929,7 +2930,8 @@ MaybeObject* JSObject::SetPropertyForResult(LookupResult* lookup,
result = self->SetNormalizedProperty(lookup, *value);
break;
case FIELD:
- result = self->FastPropertyAtPut(lookup->GetFieldIndex(), *value);
+ result = self->FastPropertyAtPut(
+ lookup->GetFieldIndex().FieldIndex(), *value);
break;
case CONSTANT_FUNCTION:
// Only replace the function if necessary.
@@ -3095,7 +3097,8 @@ MaybeObject* JSObject::SetLocalPropertyIgnoreAttributes(
break;
}
case FIELD:
- result = self->FastPropertyAtPut(lookup.GetFieldIndex(), *value);
+ result = self->FastPropertyAtPut(
+ lookup.GetFieldIndex().FieldIndex(), *value);
break;
case CONSTANT_FUNCTION:
// Only replace the function if necessary.
« no previous file with comments | « src/mips/stub-cache-mips.cc ('k') | src/property.h » ('j') | src/property.h » ('J')

Powered by Google App Engine
This is Rietveld 408576698