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

Unified Diff: src/lookup.h

Issue 464473002: Add "own" symbols support. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Fixes for 64-bit builds Created 6 years, 4 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/heap/heap.cc ('k') | src/objects.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/lookup.h
diff --git a/src/lookup.h b/src/lookup.h
index 923e8107fd3a36c159b4396b458de7962baca666..2d609c5f666c6b77851cf3917f000e18e8d5b6e0 100644
--- a/src/lookup.h
+++ b/src/lookup.h
@@ -47,7 +47,7 @@ class LookupIterator V8_FINAL BASE_EMBEDDED {
LookupIterator(Handle<Object> receiver,
Handle<Name> name,
Configuration configuration = CHECK_ALL)
- : configuration_(configuration),
+ : configuration_(ComputeConfiguration(configuration, name)),
state_(NOT_FOUND),
property_kind_(DATA),
property_encoding_(DESCRIPTOR),
@@ -66,7 +66,7 @@ class LookupIterator V8_FINAL BASE_EMBEDDED {
Handle<Name> name,
Handle<JSReceiver> holder,
Configuration configuration = CHECK_ALL)
- : configuration_(configuration),
+ : configuration_(ComputeConfiguration(configuration, name)),
state_(NOT_FOUND),
property_kind_(DATA),
property_encoding_(DESCRIPTOR),
@@ -187,6 +187,15 @@ class LookupIterator V8_FINAL BASE_EMBEDDED {
return number_;
}
+ static Configuration ComputeConfiguration(
+ Configuration configuration, Handle<Name> name) {
+ if (name->IsOwn()) {
+ return static_cast<Configuration>(configuration & CHECK_OWN);
+ } else {
+ return configuration;
+ }
+ }
+
Configuration configuration_;
State state_;
bool has_property_;
« no previous file with comments | « src/heap/heap.cc ('k') | src/objects.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698