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

Unified Diff: src/builtins.cc

Issue 1609173002: Revert of [runtime] Migrate Object.getOwnPropertyNames to C++. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@ObjectGetOwnPropertyDescriptor
Patch Set: Created 4 years, 11 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/builtins.h ('k') | src/js/v8natives.js » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/builtins.cc
diff --git a/src/builtins.cc b/src/builtins.cc
index baa1c6c38a25e9a5b58c093d76eb95d18768eb36..6d6e816f53134a3f03ad590c195648a5881fa5bd 100644
--- a/src/builtins.cc
+++ b/src/builtins.cc
@@ -1590,11 +1590,8 @@
}
-namespace {
-
-Object* GetOwnPropertyKeys(Isolate* isolate,
- BuiltinArguments<BuiltinExtraArguments::kNone> args,
- PropertyFilter filter) {
+// ES6 section 19.1.2.8 Object.getOwnPropertySymbols ( O )
+BUILTIN(ObjectGetOwnPropertySymbols) {
HandleScope scope(isolate);
Handle<Object> object = args.atOrUndefined(isolate, 1);
Handle<JSReceiver> receiver;
@@ -1602,23 +1599,9 @@
Object::ToObject(isolate, object));
Handle<FixedArray> keys;
ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
- isolate, keys, JSReceiver::GetKeys(receiver, JSReceiver::OWN_ONLY, filter,
- CONVERT_TO_STRING));
+ isolate, keys, JSReceiver::GetKeys(receiver, JSReceiver::OWN_ONLY,
+ SKIP_STRINGS, CONVERT_TO_STRING));
return *isolate->factory()->NewJSArrayWithElements(keys);
-}
-
-} // namespace
-
-
-// ES6 section 19.1.2.7 Object.getOwnPropertyNames ( O )
-BUILTIN(ObjectGetOwnPropertyNames) {
- return GetOwnPropertyKeys(isolate, args, SKIP_SYMBOLS);
-}
-
-
-// ES6 section 19.1.2.8 Object.getOwnPropertySymbols ( O )
-BUILTIN(ObjectGetOwnPropertySymbols) {
- return GetOwnPropertyKeys(isolate, args, SKIP_STRINGS);
}
« no previous file with comments | « src/builtins.h ('k') | src/js/v8natives.js » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698