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

Unified Diff: src/objects-inl.h

Issue 464473002: Add "own" symbols support. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Minor fixes 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
« src/lookup.h ('K') | « src/objects.cc ('k') | src/objects-printer.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects-inl.h
diff --git a/src/objects-inl.h b/src/objects-inl.h
index cfac520acc6092074855baece99b4e1cf0f7decc..098087aeef555c6d057e9b278383532edbcb87a0 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -3371,6 +3371,7 @@ bool Name::Equals(Handle<Name> one, Handle<Name> two) {
ACCESSORS(Symbol, name, Object, kNameOffset)
ACCESSORS(Symbol, flags, Smi, kFlagsOffset)
BOOL_ACCESSORS(Symbol, flags, is_private, kPrivateBit)
+BOOL_ACCESSORS(Symbol, flags, is_own, kOwnBit)
bool String::Equals(String* other) {
@@ -6504,6 +6505,10 @@ uint32_t Name::Hash() {
return String::cast(this)->ComputeAndSetHash();
}
+bool Name::IsOwn() {
+ return this->IsSymbol() && Symbol::cast(this)->is_own();
+}
+
StringHasher::StringHasher(int length, uint32_t seed)
: length_(length),
« src/lookup.h ('K') | « src/objects.cc ('k') | src/objects-printer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698