Index: src/isolate.cc |
diff --git a/src/isolate.cc b/src/isolate.cc |
index cb3c4a79dca7aa2feb41a3e392335d5d7de5995c..883abc0e6e96fb638faed97fcf48c88b39c63467 100644 |
--- a/src/isolate.cc |
+++ b/src/isolate.cc |
@@ -658,7 +658,7 @@ class CaptureStackTraceHelper { |
} |
if (!script_name_or_source_url_key_.is_null()) { |
- Handle<Object> result = Script::GetNameOrSourceURL(script); |
+ Handle<Object> result(script->GetNameOrSourceURL(), isolate_); |
JSObject::AddProperty(stack_frame, script_name_or_source_url_key_, result, |
NONE); |
} |
@@ -1077,7 +1077,7 @@ Object* Isolate::Throw(Object* exception, MessageLocation* location) { |
printf("Exception thrown:\n"); |
if (location) { |
Handle<Script> script = location->script(); |
- Handle<Object> name = Script::GetNameOrSourceURL(script); |
+ Handle<Object> name(script->GetNameOrSourceURL(), this); |
printf("at "); |
if (name->IsString() && String::cast(*name)->length() > 0) |
String::cast(*name)->PrintOn(stdout); |
@@ -2808,6 +2808,12 @@ bool Isolate::use_crankshaft() const { |
CpuFeatures::SupportsCrankshaft(); |
} |
+bool Isolate::NeedsSourcePositionsForProfiling() const { |
+ return FLAG_trace_deopt || FLAG_trace_turbo || FLAG_trace_turbo_graph || |
+ FLAG_turbo_profiling || is_profiling() || debug_->is_active() || |
+ logger_->is_logging(); |
+} |
+ |
bool Isolate::IsArrayOrObjectPrototype(Object* object) { |
Object* context = heap()->native_contexts_list(); |
while (!context->IsUndefined(this)) { |