mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Make struct part of unrooted_must_root handle type parameters
This commit is contained in:
parent
511e3337fb
commit
fda3eb6327
4 changed files with 40 additions and 28 deletions
|
@ -30,6 +30,7 @@ use std::default::Default;
|
|||
#[derive(JSTraceable)]
|
||||
#[privatize]
|
||||
#[allow(raw_pointer_derive)]
|
||||
#[must_root]
|
||||
pub struct BrowsingContext {
|
||||
history: Vec<SessionHistoryEntry>,
|
||||
active_index: usize,
|
||||
|
|
|
@ -14,6 +14,7 @@ use std::rc::Rc;
|
|||
|
||||
/// Encapsulates a handle to a frame in a frame tree.
|
||||
#[derive(JSTraceable)]
|
||||
#[allow(unrooted_must_root)] // FIXME(#6686) this is wrong
|
||||
pub struct Page {
|
||||
/// Pipeline id associated with this page.
|
||||
id: PipelineId,
|
||||
|
|
|
@ -287,6 +287,8 @@ impl Drop for StackRootTLS {
|
|||
/// Information for an entire page. Pages are top-level browsing contexts and can contain multiple
|
||||
/// frames.
|
||||
#[derive(JSTraceable)]
|
||||
// ScriptTask instances are rooted on creation, so this is okay
|
||||
#[allow(unrooted_must_root)]
|
||||
pub struct ScriptTask {
|
||||
/// A handle to the information pertaining to page layout
|
||||
page: DOMRefCell<Option<Rc<Page>>>,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue