-
-
Notifications
You must be signed in to change notification settings - Fork 3k
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
Implement the preserveWrapperCallback API to allow our DOM objects to be stored in WeakMaps. #7218
Comments
Both of those exist and are tested. What is the code that isn't working? http://mxr.mozilla.org/servo/source/components/script/dom/htmlcanvaselement.rs#241 |
|
Looks like we need to implement the preserveWrapperCallback API to allow our DOM objects to be stored in WeakMaps. |
WeakMaps? Where are they? Do they do what I think they do? Can we use them from Rust for ranges and things like that? |
They're SpiderMonkey things. I don't even know the situation for using them from C++, let alone Rust. |
This involves calling |
... as well as adding tests in window and worker contexts. |
#7620 has a great testcase for the window context that we can copy. |
Minimimized GitHub testcase:
|
@jdm Also, rust-mozjs expects a function returning a u8, whereas actually it is |
I do not know anything about the implications of using bool/u8 in FFI, unfortunately. |
Use |
A naive |
Not sure if getContext is not a method of an HTMLCanvasElement, or if createElement is not a method of the document object?
The text was updated successfully, but these errors were encountered: