diff options
| author | Palmer Cox <p@lmercox.com> | 2014-01-14 22:32:24 -0500 |
|---|---|---|
| committer | Palmer Cox <p@lmercox.com> | 2014-01-18 01:15:15 -0500 |
| commit | 3fd8c8b3306ae33bdc85811aa410ba01967922bc (patch) | |
| tree | 36818b3c2f6f3c6ba8e145f4a1098dcb87f5bb44 /src/libstd/rt | |
| parent | c58d2bacb78ed0d2b9c0c0909e56f390b525aabd (diff) | |
| download | rust-3fd8c8b3306ae33bdc85811aa410ba01967922bc.tar.gz rust-3fd8c8b3306ae33bdc85811aa410ba01967922bc.zip | |
Rename iterators for consistency
Rename existing iterators to get rid of the Iterator suffix and to give them names that better describe the things being iterated over.
Diffstat (limited to 'src/libstd/rt')
| -rw-r--r-- | src/libstd/rt/task.rs | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/libstd/rt/task.rs b/src/libstd/rt/task.rs index 4df626446c4..5041c4b6165 100644 --- a/src/libstd/rt/task.rs +++ b/src/libstd/rt/task.rs @@ -79,7 +79,7 @@ pub struct Death { on_exit: Option<proc(TaskResult)>, } -pub struct BlockedTaskIterator { +pub struct BlockedTasks { priv inner: UnsafeArc<AtomicUint>, } @@ -300,7 +300,7 @@ impl Drop for Task { } } -impl Iterator<BlockedTask> for BlockedTaskIterator { +impl Iterator<BlockedTask> for BlockedTasks { fn next(&mut self) -> Option<BlockedTask> { Some(Shared(self.inner.clone())) } @@ -331,7 +331,7 @@ impl BlockedTask { } /// Converts one blocked task handle to a list of many handles to the same. - pub fn make_selectable(self, num_handles: uint) -> Take<BlockedTaskIterator> + pub fn make_selectable(self, num_handles: uint) -> Take<BlockedTasks> { let arc = match self { Owned(task) => { @@ -340,7 +340,7 @@ impl BlockedTask { } Shared(arc) => arc.clone(), }; - BlockedTaskIterator{ inner: arc }.take(num_handles) + BlockedTasks{ inner: arc }.take(num_handles) } /// Convert to an unsafe uint value. Useful for storing in a pipe's state |
