mirror of
https://github.com/servo/servo.git
synced 2025-06-06 16:45:39 +00:00
Fix tyvar_behind_raw_pointer warnings
https://github.com/rust-lang/rust/issues/46906
This commit is contained in:
parent
cee2aadd82
commit
4d459bce32
20 changed files with 55 additions and 53 deletions
|
@ -72,7 +72,7 @@ impl Promise {
|
|||
#[allow(unsafe_code)]
|
||||
pub fn new(global: &GlobalScope) -> Rc<Promise> {
|
||||
let cx = global.get_cx();
|
||||
rooted!(in(cx) let mut obj = ptr::null_mut());
|
||||
rooted!(in(cx) let mut obj = ptr::null_mut::<JSObject>());
|
||||
unsafe {
|
||||
Promise::create_js_promise(cx, HandleObject::null(), obj.handle_mut());
|
||||
Promise::new_with_js_promise(obj.handle(), cx)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue