You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We left the implementation of [[HostDefined]] fields for Script and Module as a future improvement, but it's pretty necessary for users that want to store additional data on a runnable.
Wouldn't this use HostDefined struct? Or is [[HostDefined]] meant to store only 1 object in Script and Module?
Both are good. We can implement it using HostDefined for now and if there's not much usage for storing multiple objects, we can just return to a simple Box<dyn NativeObject>.
We left the implementation of
[[HostDefined]]
fields forScript
andModule
as a future improvement, but it's pretty necessary for users that want to store additional data on a runnable.Script
:boa/boa_engine/src/script.rs
Lines 45 to 53 in 348c757
Module
:boa/boa_engine/src/module/mod.rs
Lines 284 to 291 in 348c757
Probably a simple
GcRefCell<Box<dyn NativeObject>>
and an accessor/mutable accessor should be enough for both.The text was updated successfully, but these errors were encountered: