mirror of
https://github.com/servo/servo.git
synced 2025-06-14 11:24:33 +00:00
Address review comments; add docs
This commit is contained in:
parent
521d8bc32e
commit
a9f651cfa1
2 changed files with 9 additions and 5 deletions
|
@ -26,6 +26,10 @@ declare_lint!(UNROOTED_MUST_ROOT, Deny,
|
|||
///
|
||||
/// This helps catch most situations where pointers like `JS<T>` are used in a way that they can be invalidated by a
|
||||
/// GC pass.
|
||||
///
|
||||
/// Structs which have their own mechanism of rooting their unrooted contents (e.g. `ScriptTask`)
|
||||
/// can be marked as `#[allow(unrooted_must_root)]`. Smart pointers which root their interior type
|
||||
/// can be marked as `#[allow_unrooted_interior]`
|
||||
pub struct UnrootedPass {
|
||||
in_new_function: bool
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue