mirror of
https://github.com/servo/servo.git
synced 2025-08-06 22:15:33 +01:00
Replace Root::deref() calls by Root::r() calls where possible.
This changes those calls that were already sound.
This commit is contained in:
parent
c9f26dfd59
commit
1dad710063
61 changed files with 479 additions and 471 deletions
|
@ -64,15 +64,15 @@ impl ErrorEvent {
|
|||
colno: u32,
|
||||
error: JSVal) -> Temporary<ErrorEvent> {
|
||||
let ev = ErrorEvent::new_uninitialized(global).root();
|
||||
let event: JSRef<Event> = EventCast::from_ref(*ev);
|
||||
let event: JSRef<Event> = EventCast::from_ref(ev.r());
|
||||
event.InitEvent(type_, bubbles == EventBubbles::Bubbles,
|
||||
cancelable == EventCancelable::Cancelable);
|
||||
*ev.message.borrow_mut() = message;
|
||||
*ev.filename.borrow_mut() = filename;
|
||||
ev.lineno.set(lineno);
|
||||
ev.colno.set(colno);
|
||||
ev.error.set(error);
|
||||
Temporary::from_rooted(*ev)
|
||||
*ev.r().message.borrow_mut() = message;
|
||||
*ev.r().filename.borrow_mut() = filename;
|
||||
ev.r().lineno.set(lineno);
|
||||
ev.r().colno.set(colno);
|
||||
ev.r().error.set(error);
|
||||
Temporary::from_rooted(ev.r())
|
||||
}
|
||||
|
||||
pub fn Constructor(global: &GlobalRef,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue