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

Unified Diff: src/builtins.cc

Issue 2137203002: [intrinsics] Remove obsolete intrinsics. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Really nuke TO_NAME. Created 4 years, 5 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/compiler/js-intrinsic-lowering.h » ('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 13bea6310200ab0b9fa20c54627c596c2aed7f02..d386ae9cf6ff01693434e99766b3a2d0bb7933f4 100644
--- a/src/builtins.cc
+++ b/src/builtins.cc
@@ -4994,7 +4994,26 @@ BUILTIN(AsyncFunctionConstructor) {
return *func;
}
-// ES6 19.1.3.6 Object.prototype.toString
+// -----------------------------------------------------------------------------
+// ES6 section 19.1 Object Objects
+
+// ES6 section 19.1.3.4 Object.prototype.propertyIsEnumerable ( V )
+BUILTIN(ObjectPrototypePropertyIsEnumerable) {
+ HandleScope scope(isolate);
+ Handle<JSReceiver> object;
+ Handle<Name> name;
+ ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
+ isolate, name, Object::ToName(isolate, args.atOrUndefined(isolate, 1)));
+ ASSIGN_RETURN_FAILURE_ON_EXCEPTION(
+ isolate, object, JSReceiver::ToObject(isolate, args.receiver()));
+ Maybe<PropertyAttributes> maybe =
+ JSReceiver::GetOwnPropertyAttributes(object, name);
+ if (!maybe.IsJust()) return isolate->heap()->exception();
+ if (maybe.FromJust() == ABSENT) return isolate->heap()->false_value();
+ return isolate->heap()->ToBoolean((maybe.FromJust() & DONT_ENUM) == 0);
+}
+
+// ES6 section 19.1.3.6 Object.prototype.toString
BUILTIN(ObjectProtoToString) {
HandleScope scope(isolate);
Handle<Object> object = args.at<Object>(0);
« no previous file with comments | « src/builtins.h ('k') | src/compiler/js-intrinsic-lowering.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698