Index: third_party/WebKit/Source/core/inspector/v8/V8JavaScriptCallFrame.cpp |
diff --git a/third_party/WebKit/Source/core/inspector/v8/V8JavaScriptCallFrame.cpp b/third_party/WebKit/Source/core/inspector/v8/V8JavaScriptCallFrame.cpp |
index 913cc57d6f6123e7216db7b6558921470ce22b1a..79448cec2575d45dc8114cf28175ea6fa8d15ba4 100644 |
--- a/third_party/WebKit/Source/core/inspector/v8/V8JavaScriptCallFrame.cpp |
+++ b/third_party/WebKit/Source/core/inspector/v8/V8JavaScriptCallFrame.cpp |
@@ -17,7 +17,7 @@ namespace { |
void callerAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
JavaScriptCallFrame* caller = impl->caller(); |
if (!caller) |
return; |
@@ -30,37 +30,37 @@ void callerAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallba |
void sourceIDAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->sourceID()); |
} |
void lineAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->line()); |
} |
void columnAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->column()); |
} |
void scopeChainAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->scopeChain()); |
} |
void thisObjectAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->thisObject()); |
} |
void stepInPositionsAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
CString cstr = impl->stepInPositions().utf8(); |
v8::Local<v8::Name> result = v8::String::NewFromUtf8(info.GetIsolate(), cstr.data(), v8::NewStringType::kNormal, cstr.length()).ToLocalChecked(); |
info.GetReturnValue().Set(result); |
@@ -68,7 +68,7 @@ void stepInPositionsAttributeGetterCallback(v8::Local<v8::Name>, const v8::Prope |
void functionNameAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
CString cstr = impl->functionName().utf8(); |
v8::Local<v8::Name> result = v8::String::NewFromUtf8(info.GetIsolate(), cstr.data(), v8::NewStringType::kNormal, cstr.length()).ToLocalChecked(); |
info.GetReturnValue().Set(result); |
@@ -76,37 +76,37 @@ void functionNameAttributeGetterCallback(v8::Local<v8::Name>, const v8::Property |
void functionLineAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->functionLine()); |
} |
void functionColumnAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->functionColumn()); |
} |
void isAtReturnAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->isAtReturn()); |
} |
void returnValueAttributeGetterCallback(v8::Local<v8::Name>, const v8::PropertyCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->returnValue()); |
} |
void evaluateWithExceptionDetailsMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
info.GetReturnValue().Set(impl->evaluateWithExceptionDetails(info[0], info[1])); |
} |
void restartMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
v8::MaybeLocal<v8::Value> result = impl->restart(); |
v8::Local<v8::Value> value; |
if (result.ToLocal(&value)) |
@@ -115,7 +115,7 @@ void restartMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
void setVariableValueMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
v8::Maybe<int32_t> maybeScopeIndex = info[0]->Int32Value(info.GetIsolate()->GetCurrentContext()); |
if (maybeScopeIndex.IsNothing()) |
return; |
@@ -129,7 +129,7 @@ void setVariableValueMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& i |
void scopeTypeMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
v8::Maybe<int32_t> maybeScopeIndex = info[0]->Int32Value(info.GetIsolate()->GetCurrentContext()); |
if (maybeScopeIndex.IsNothing()) |
return; |
@@ -139,7 +139,7 @@ void scopeTypeMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
void scopeNameMethodCallback(const v8::FunctionCallbackInfo<v8::Value>& info) |
{ |
- JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.Holder()); |
+ JavaScriptCallFrame* impl = V8JavaScriptCallFrame::unwrap(info.GetIsolate()->GetCurrentContext(), info.Holder()); |
v8::Maybe<int32_t> maybeScopeIndex = info[0]->Int32Value(info.GetIsolate()->GetCurrentContext()); |
if (maybeScopeIndex.IsNothing()) |
return; |
@@ -193,9 +193,9 @@ v8::Local<v8::Object> V8JavaScriptCallFrame::wrap(v8::Local<v8::FunctionTemplate |
return JavaScriptCallFrameWrapper::wrap(constructorTemplate, context, frame); |
} |
-JavaScriptCallFrame* V8JavaScriptCallFrame::unwrap(v8::Local<v8::Object> object) |
+JavaScriptCallFrame* V8JavaScriptCallFrame::unwrap(v8::Local<v8::Context> context, v8::Local<v8::Object> object) |
{ |
- return JavaScriptCallFrameWrapper::unwrap(object); |
+ return JavaScriptCallFrameWrapper::unwrap(context, object); |
} |
} // namespace blink |