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

Unified Diff: src/objects.cc

Issue 1423723002: Map v8::Function to JSReceiver + IsCallable (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: updates Created 5 years, 2 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/messages.cc ('k') | test/cctest/compiler/function-tester.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/objects.cc
diff --git a/src/objects.cc b/src/objects.cc
index 1e5315b978e67fb8e9314cd993a5184f60ff3269..aa200482871bb04e17e2fd87e51c4ba53f331e8e 100644
--- a/src/objects.cc
+++ b/src/objects.cc
@@ -11983,11 +11983,11 @@ Handle<Object> Script::GetNameOrSourceURL(Handle<Script> script) {
Handle<Object> property = Object::GetProperty(
script_wrapper, name_or_source_url_key).ToHandleChecked();
DCHECK(property->IsJSFunction());
- Handle<JSFunction> method = Handle<JSFunction>::cast(property);
Handle<Object> result;
// Do not check against pending exception, since this function may be called
// when an exception has already been pending.
- if (!Execution::TryCall(method, script_wrapper, 0, NULL).ToHandle(&result)) {
+ if (!Execution::TryCall(isolate, property, script_wrapper, 0, NULL)
+ .ToHandle(&result)) {
return isolate->factory()->undefined_value();
}
return result;
« no previous file with comments | « src/messages.cc ('k') | test/cctest/compiler/function-tester.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698