-
Notifications
You must be signed in to change notification settings - Fork 320
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: cppgc NameProvider #1528
feat: cppgc NameProvider #1528
Conversation
a1022c1
to
3ebec4c
Compare
tests/test_cppgc.rs
Outdated
@@ -44,6 +44,10 @@ fn cppgc_object_wrap() { | |||
TRACE_COUNT.fetch_add(1, Ordering::SeqCst); | |||
visitor.trace(&self.value); | |||
} | |||
|
|||
fn get_name(&self) -> Option<&'static std::ffi::CStr> { | |||
Some(c"Wrap") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test somewhere that you can see this value?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
afaik there isn't really an easy way to test this since heap dumps need to be loaded into chrome to be read.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
maybe just see if it contains the byte string Wrap
? (maybe use a different magic string)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
implements NameProvider, but I didn't want RustObj to grow beyond 2 pointers, so replace it with a dyn pointer and use that to dispatch.