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

Unified Diff: src/objects-inl.h

Issue 1492653004: [cleanup] Introduce PropertyFilter (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: windows ♥ Created 5 years 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/objects.cc ('k') | src/property-details.h » ('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 24c8c14f1ced7a1b8a266342cf287cf81f22b18a..586e23d55921db8be5636c5a2a982ac57b9c8d8d 100644
--- a/src/objects-inl.h
+++ b/src/objects-inl.h
@@ -280,19 +280,12 @@ bool Object::KeyEquals(Object* second) {
}
-bool Object::FilterKey(PropertyAttributes filter) {
- if ((filter & SYMBOLIC) && IsSymbol()) {
- return true;
- }
-
- if ((filter & PRIVATE_SYMBOL) && IsSymbol() &&
- Symbol::cast(this)->is_private()) {
- return true;
- }
-
- if ((filter & STRING) && !IsSymbol()) {
- return true;
+bool Object::FilterKey(PropertyFilter filter) {
+ if (IsSymbol()) {
+ if (filter & SKIP_SYMBOLS) return true;
+ if (Symbol::cast(this)->is_private()) return true;
}
+ if ((filter & SKIP_STRINGS) && !IsSymbol()) return true;
return false;
}
« no previous file with comments | « src/objects.cc ('k') | src/property-details.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698