mirror of
https://github.com/servo/servo.git
synced 2025-08-03 04:30:10 +01:00
Add unrooted_must_root lint for usages of JS<T> in let/for bindings
This commit is contained in:
parent
12dc54d238
commit
bded5c3703
11 changed files with 55 additions and 15 deletions
|
@ -310,8 +310,8 @@ impl Document {
|
|||
}
|
||||
|
||||
pub fn new(window: &JSRef<Window>, url: Option<Url>, doctype: IsHTMLDocument, content_type: Option<DOMString>) -> Temporary<Document> {
|
||||
let document = Document::new_inherited(window, url, doctype, content_type);
|
||||
let document = reflect_dom_object(box document, &Window(*window),
|
||||
let document = reflect_dom_object(box Document::new_inherited(window, url, doctype, content_type),
|
||||
&Window(*window),
|
||||
DocumentBinding::Wrap).root();
|
||||
|
||||
let node: &JSRef<Node> = NodeCast::from_ref(&*document);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue