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

Unified Diff: src/runtime/runtime-internal.cc

Issue 1287203006: Native context: Fix issue when running prologue.js before runtime.js (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 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/runtime/runtime.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/runtime/runtime-internal.cc
diff --git a/src/runtime/runtime-internal.cc b/src/runtime/runtime-internal.cc
index 97edea53369078a99588b1832a6ad62dfeb07850..e6ea9fd3b78165bc47a75451b82ca4c90606d9c3 100644
--- a/src/runtime/runtime-internal.cc
+++ b/src/runtime/runtime-internal.cc
@@ -45,42 +45,6 @@ RUNTIME_FUNCTION(Runtime_ImportExperimentalToRuntime) {
}
-RUNTIME_FUNCTION(Runtime_InstallFunctionsFromArray) {
- HandleScope scope(isolate);
- DCHECK(args.length() == 3);
- CONVERT_ARG_HANDLE_CHECKED(JSObject, object, 0);
- CONVERT_PROPERTY_ATTRIBUTES_CHECKED(attrs, 1);
- CONVERT_ARG_HANDLE_CHECKED(JSArray, functions, 2);
- RUNTIME_ASSERT(isolate->bootstrapper()->IsActive());
-
- int num_items = NumberToInt32(functions->length()) / 2;
- if (!object->IsJSGlobalObject() && object->HasFastProperties()) {
- JSObject::NormalizeProperties(object, KEEP_INOBJECT_PROPERTIES, num_items,
- "InstallFunctions");
- }
-
- Handle<FixedArray> array(FixedArray::cast(functions->elements()));
- for (int i = 0; i < num_items; ++i) {
- RUNTIME_ASSERT(array->get(i * 2)->IsString());
- RUNTIME_ASSERT(array->get(i * 2 + 1)->IsJSFunction());
- Handle<String> name(String::cast(array->get(i * 2)));
- Handle<JSFunction> fun(JSFunction::cast(array->get(i * 2 + 1)));
- fun->shared()->set_name(*name);
- RUNTIME_ASSERT(fun->RemovePrototype());
- fun->shared()->set_native(true);
- RETURN_FAILURE_ON_EXCEPTION(
- isolate,
- JSObject::SetOwnPropertyIgnoreAttributes(object, name, fun, attrs));
- }
-
- if (!object->IsJSGlobalObject()) {
- JSObject::MigrateSlowToFast(object, 0, "InstallFunctions");
- }
-
- return isolate->heap()->undefined_value();
-}
-
-
RUNTIME_FUNCTION(Runtime_Throw) {
HandleScope scope(isolate);
DCHECK(args.length() == 1);
« no previous file with comments | « src/runtime/runtime.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698