diff --git a/components/compositing/compositor.rs b/components/compositing/compositor.rs index ef47ffcb438..a20cccb6346 100644 --- a/components/compositing/compositor.rs +++ b/components/compositing/compositor.rs @@ -512,7 +512,7 @@ impl IOCompositor { match ipc::channel() { Ok((sender, receiver)) => { self.time_profiler_chan.send(time::ProfilerMsg::Exit(sender)); - receiver.recv(); + let _ = receiver.recv(); }, Err(_) => {}, } diff --git a/components/net/filemanager_thread.rs b/components/net/filemanager_thread.rs index db9d87f86ac..04a19a3a3d6 100644 --- a/components/net/filemanager_thread.rs +++ b/components/net/filemanager_thread.rs @@ -18,14 +18,14 @@ pub struct FileManager { } impl FileManager { - fn new(recv: IpcReceiver) -> FileManager { + pub fn new(recv: IpcReceiver) -> FileManager { FileManager { receiver: recv, idmap: RefCell::new(HashMap::new()), } } - fn new_thread() -> IpcSender { + pub fn new_thread() -> IpcSender { let (chan, recv) = ipc::channel().unwrap(); spawn_named("FileManager".to_owned(), move || { diff --git a/components/profile/time.rs b/components/profile/time.rs index 5661d07d57e..3713a048b5b 100644 --- a/components/profile/time.rs +++ b/components/profile/time.rs @@ -85,7 +85,7 @@ impl Formattable for Option { impl Formattable for ProfilerCategory { // some categories are subcategories of LayoutPerformCategory // and should be printed to indicate this - fn format(&self, output: &Option) -> String { + fn format(&self, _output: &Option) -> String { let padding = match *self { ProfilerCategory::LayoutStyleRecalc | ProfilerCategory::LayoutRestyleDamagePropagation | @@ -213,7 +213,7 @@ impl Profiler { match port.recv() { Err(_) => break, Ok(ProfilerMsg::Exit(chan)) => { - chan.send(()); + let _ = chan.send(()); break; }, _ => {} @@ -315,7 +315,7 @@ impl Profiler { ProfilerMsg::Exit(chan) => { heartbeats::cleanup(); self.print_buckets(); - chan.send(()); + let _ = chan.send(()); return false; }, }; @@ -334,7 +334,7 @@ impl Profiler { Ok(file) => file, }; write!(file, "_category_, _incremental?_, _iframe?_, _url_, _mean (ms)_, _median (ms)_, _min (ms)_, \ - _max (ms)_, _events_\n"); + _max (ms)_, _events_\n").unwrap(); for (&(ref category, ref meta), ref mut data) in &mut self.buckets { data.sort_by(|a, b| { if a < b { @@ -352,11 +352,11 @@ impl Profiler { data.iter().fold(-f64::INFINITY, |a, &b| a.max(b))); write!(file, "{}, {}, {:15.4}, {:15.4}, {:15.4}, {:15.4}, {:15}\n", category.format(&self.output), meta.format(&self.output), - mean, median, min, max, data_len); + mean, median, min, max, data_len).unwrap(); } } }, - Some(OutputOptions::Stdout(ref period)) => { + Some(OutputOptions::Stdout(_)) => { let stdout = io::stdout(); let mut lock = stdout.lock();