summaryrefslogtreecommitdiff
path: root/core/inspector.rs
diff options
context:
space:
mode:
authorBartek IwaƄczuk <biwanczuk@gmail.com>2023-02-07 13:36:41 +0100
committerGitHub <noreply@github.com>2023-02-07 13:36:41 +0100
commit65500f36e870b4ada3996b06aa287e30177d21a3 (patch)
tree9e17fd939e682d985804f727d604d07ecb1e80d1 /core/inspector.rs
parenta4988d00dad8b5e665cd1f38826674d1317e8cf9 (diff)
chore: upgrade rusty_v8 to 0.62.2 (#17604)
Co-authored-by: Bert Belder <bertbelder@gmail.com>
Diffstat (limited to 'core/inspector.rs')
-rw-r--r--core/inspector.rs18
1 files changed, 18 insertions, 0 deletions
diff --git a/core/inspector.rs b/core/inspector.rs
index 2b03d663d..c83784fe3 100644
--- a/core/inspector.rs
+++ b/core/inspector.rs
@@ -111,6 +111,16 @@ impl v8::inspector::V8InspectorClientImpl for JsRuntimeInspector {
&self.v8_inspector_client
}
+ unsafe fn base_ptr(
+ this: *const Self,
+ ) -> *const v8::inspector::V8InspectorClientBase
+ where
+ Self: Sized,
+ {
+ // SAFETY: this pointer is valid for the whole lifetime of inspector
+ unsafe { std::ptr::addr_of!((*this).v8_inspector_client) }
+ }
+
fn base_mut(&mut self) -> &mut v8::inspector::V8InspectorClientBase {
&mut self.v8_inspector_client
}
@@ -647,6 +657,14 @@ impl v8::inspector::ChannelImpl for InspectorSession {
&self.v8_channel
}
+ unsafe fn base_ptr(this: *const Self) -> *const v8::inspector::ChannelBase
+ where
+ Self: Sized,
+ {
+ // SAFETY: this pointer is valid for the whole lifetime of inspector
+ unsafe { std::ptr::addr_of!((*this).v8_channel) }
+ }
+
fn base_mut(&mut self) -> &mut v8::inspector::ChannelBase {
&mut self.v8_channel
}