(also, add impl AsRef for Gc, and remove extra borrows from other Gc-taking methods)
This is sound, as &'gc T doesn't implement Collect (unless 'gc ends up being 'static, which will be impossible once #63 is merged) and so cannot escape the current arena callback by being stored in the GC root.
(also, add
impl AsRef
forGc
, and remove extra borrows from otherGc
-taking methods)This is sound, as
&'gc T
doesn't implementCollect
(unless'gc
ends up being'static
, which will be impossible once #63 is merged) and so cannot escape the current arena callback by being stored in the GC root.