Skip to content

Commit 46ea78e

Browse files
committed
Fix some build warnings.
1 parent 09e6f4a commit 46ea78e

4 files changed

Lines changed: 6 additions & 12 deletions

File tree

components/compositing/compositor.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1932,12 +1932,10 @@ impl<Window: WindowMethods> IOCompositor<Window> {
19321932
scroll_offset: scroll_layer_state.scroll_offset,
19331933
};
19341934
let pipeline_id = scroll_layer_state.pipeline_id;
1935-
match stacking_context_scroll_states_per_pipeline.entry(pipeline_id) {
1936-
Vacant(mut entry) => {
1937-
entry.insert(vec![stacking_context_scroll_state]);
1938-
}
1939-
Occupied(mut entry) => entry.get_mut().push(stacking_context_scroll_state),
1940-
}
1935+
stacking_context_scroll_states_per_pipeline
1936+
.entry(pipeline_id)
1937+
.or_insert(vec![])
1938+
.push(stacking_context_scroll_state);
19411939
}
19421940

19431941
for (pipeline_id, stacking_context_scroll_states) in

components/script/dom/dedicatedworkerglobalscope.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,6 @@ impl DedicatedWorkerGlobalScope {
212212
worker_url: Url,
213213
id: PipelineId,
214214
from_devtools_receiver: IpcReceiver<DevtoolScriptControlMsg>,
215-
parent_rt: SharedRt,
216215
worker_rt_for_mainthread: Arc<Mutex<Option<SharedRt>>>,
217216
worker: TrustedWorkerAddress,
218217
parent_sender: Box<ScriptChan + Send>,

components/script/dom/worker.rs

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ use dom::messageevent::MessageEvent;
2222
use dom::workerglobalscope::WorkerGlobalScopeInit;
2323
use ipc_channel::ipc;
2424
use js::jsapi::{HandleValue, JSContext, JSRuntime, RootedValue};
25-
use js::jsapi::{JSAutoCompartment, JS_GetRuntime, JS_RequestInterruptCallback};
25+
use js::jsapi::{JSAutoCompartment, JS_RequestInterruptCallback};
2626
use js::jsval::UndefinedValue;
2727
use js::rust::Runtime;
2828
use msg::constellation_msg::{PipelineId, ReferrerPolicy};
@@ -146,10 +146,8 @@ impl Worker {
146146
closing: closing,
147147
};
148148

149-
let shared_rt = SharedRt { rt: unsafe { JS_GetRuntime(global.get_cx()) } };
150-
151149
DedicatedWorkerGlobalScope::run_worker_scope(
152-
init, worker_url, global.pipeline(), devtools_receiver, shared_rt, worker.runtime.clone(), worker_ref,
150+
init, worker_url, global.pipeline(), devtools_receiver, worker.runtime.clone(), worker_ref,
153151
global.script_chan(), sender, receiver, worker_load_origin);
154152

155153
Ok(worker)

components/script/script_thread.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,6 @@ use std::borrow::ToOwned;
8888
use std::cell::{Cell, RefCell};
8989
use std::collections::HashSet;
9090
use std::option::Option;
91-
use std::ptr;
9291
use std::rc::Rc;
9392
use std::result::Result;
9493
use std::sync::atomic::{Ordering, AtomicBool};

0 commit comments

Comments
 (0)