about summary refs log tree commit diff
path: root/src/libstd/task
diff options
context:
space:
mode:
authorDaniel Farina <daniel@fdr.io>2013-05-30 03:16:33 -0700
committerDaniel Farina <daniel@fdr.io>2013-05-30 13:08:18 -0700
commitaef1e10eba812b8144b0a4ac8d9b6e690c6e5ca7 (patch)
treeceb3263dbb1b692ea87761c26435fb34a45e7695 /src/libstd/task
parenta39429887a570f05c5da3e5dc8dfbcb6eea98f49 (diff)
downloadrust-aef1e10eba812b8144b0a4ac8d9b6e690c6e5ca7.tar.gz
rust-aef1e10eba812b8144b0a4ac8d9b6e690c6e5ca7.zip
Remove unnecessary 'use' forms
Fix a laundry list of warnings involving unused imports that glutted
up compilation output.  There are more, but there seems to be some
false positives (where 'remedy' appears to break the build), but this
particular set of fixes seems safe.
Diffstat (limited to 'src/libstd/task')
-rw-r--r--src/libstd/task/mod.rs10
-rw-r--r--src/libstd/task/spawn.rs6
2 files changed, 8 insertions, 8 deletions
diff --git a/src/libstd/task/mod.rs b/src/libstd/task/mod.rs
index 28fb73e6eef..b68abca8605 100644
--- a/src/libstd/task/mod.rs
+++ b/src/libstd/task/mod.rs
@@ -1,4 +1,4 @@
-// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
+// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGHT
 // file at the top-level directory of this distribution and at
 // http://rust-lang.org/COPYRIGHT.
 //
@@ -37,22 +37,22 @@
 
 use prelude::*;
 
-use cast;
 use cell::Cell;
 use cmp::Eq;
 use comm::{stream, Chan, GenericChan, GenericPort, Port};
-use comm;
-use ptr;
 use result::Result;
 use result;
 use rt::{context, OldTaskContext};
 use task::rt::{task_id, sched_id};
-use task;
 use unstable::finally::Finally;
 use util::replace;
 use util;
 
+#[cfg(test)] use cast;
 #[cfg(test)] use comm::SharedChan;
+#[cfg(test)] use comm;
+#[cfg(test)] use ptr;
+#[cfg(test)] use task;
 
 mod local_data_priv;
 pub mod rt;
diff --git a/src/libstd/task/spawn.rs b/src/libstd/task/spawn.rs
index 0b345b88d62..35cf6de3a15 100644
--- a/src/libstd/task/spawn.rs
+++ b/src/libstd/task/spawn.rs
@@ -1,4 +1,4 @@
-// Copyright 2012 The Rust Project Developers. See the COPYRIGHT
+// Copyright 2012-2013 The Rust Project Developers. See the COPYRIGHT
 // file at the top-level directory of this distribution and at
 // http://rust-lang.org/COPYRIGHT.
 //
@@ -79,7 +79,6 @@ use cast;
 use cell::Cell;
 use container::Map;
 use comm::{Chan, GenericChan};
-use comm;
 use ptr;
 use hashmap::HashSet;
 use task::local_data_priv::{local_get, local_set, OldHandle};
@@ -89,13 +88,14 @@ use task::{Failure, ManualThreads, PlatformThread, SchedOpts, SingleThreaded};
 use task::{Success, TaskOpts, TaskResult, ThreadPerCore, ThreadPerTask};
 use task::{ExistingScheduler, SchedulerHandle};
 use task::unkillable;
-use task;
 use uint;
 use util;
 use unstable::sync::{Exclusive, exclusive};
 use rt::local::Local;
 
 #[cfg(test)] use task::default_task_opts;
+#[cfg(test)] use comm;
+#[cfg(test)] use task;
 
 macro_rules! move_it (
     { $x:expr } => ( unsafe { let y = *ptr::to_unsafe_ptr(&($x)); y } )