Skip to content

Commit 6ac59b3

Browse files
committed
---
yaml --- r: 85941 b: refs/heads/dist-snap c: a6835dd h: refs/heads/master i: 85939: b667b03 v: v3
1 parent f34c694 commit 6ac59b3

File tree

10 files changed

+22
-37
lines changed

10 files changed

+22
-37
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: 0983ebe5310d4eb6d289f636f7ed0536c08bbc0e
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/dist-snap: 58c3fa92eda837cdb9be2ad206d7efd3fe402110
9+
refs/heads/dist-snap: a6835dd3cb1abaf3e8699e58b99e2ecb43611414
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1212
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/src/libstd/iter.rs

Lines changed: 0 additions & 26 deletions
This file was deleted.

branches/dist-snap/src/libstd/num/num.rs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -80,6 +80,19 @@ pub trait Signed: Num
8080

8181
pub trait Unsigned: Num {}
8282

83+
/// Times trait
84+
///
85+
/// ~~~ {.rust}
86+
/// use num::Times;
87+
/// let ten = 10 as uint;
88+
/// let mut accum = 0;
89+
/// do ten.times { accum += 1; }
90+
/// ~~~
91+
///
92+
pub trait Times {
93+
fn times(&self, it: &fn());
94+
}
95+
8396
pub trait Integer: Num
8497
+ Orderable
8598
+ Div<Self,Self>

branches/dist-snap/src/libstd/num/uint.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010

1111
//! Operations and constants for `uint`
1212
13-
use iter;
13+
use num;
1414
use sys;
1515

1616
pub use self::generated::*;
@@ -70,7 +70,7 @@ pub fn div_round(x: uint, y: uint) -> uint {
7070
///
7171
pub fn div_floor(x: uint, y: uint) -> uint { return x / y; }
7272

73-
impl iter::Times for uint {
73+
impl num::Times for uint {
7474
#[inline]
7575
///
7676
/// A convenience form for basic repetition. Given a uint `x`,
@@ -162,7 +162,7 @@ fn test_div() {
162162

163163
#[test]
164164
pub fn test_times() {
165-
use iter::Times;
165+
use num::Times;
166166
let ten = 10 as uint;
167167
let mut accum = 0;
168168
do ten.times { accum += 1; }

branches/dist-snap/src/libstd/prelude.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ pub use cmp::{Eq, ApproxEq, Ord, TotalEq, TotalOrd, Ordering, Less, Equal, Great
4949
pub use char::Char;
5050
pub use container::{Container, Mutable, Map, MutableMap, Set, MutableSet};
5151
pub use hash::Hash;
52-
pub use iter::Times;
52+
pub use num::Times;
5353
pub use iterator::{FromIterator, Extendable};
5454
pub use iterator::{Iterator, DoubleEndedIterator, RandomAccessIterator, ClonableIterator};
5555
pub use iterator::{OrdIterator, MutableDoubleEndedIterator};

branches/dist-snap/src/libstd/rt/comm.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -718,7 +718,7 @@ mod test {
718718
use option::*;
719719
use rt::test::*;
720720
use cell::Cell;
721-
use iter::Times;
721+
use num::Times;
722722
use rt::util;
723723

724724
#[test]

branches/dist-snap/src/libstd/rt/sched.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1114,7 +1114,7 @@ mod test {
11141114
#[test]
11151115
fn multithreading() {
11161116
use rt::comm::*;
1117-
use iter::Times;
1117+
use num::Times;
11181118
use vec::OwnedVector;
11191119
use container::Container;
11201120

branches/dist-snap/src/libstd/select.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,7 @@ pub fn select2<TA, A: SelectPort<TA>, TB, B: SelectPort<TB>>(mut a: A, mut b: B)
126126
mod test {
127127
use super::*;
128128
use clone::Clone;
129-
use iter::Times;
129+
use num::Times;
130130
use option::*;
131131
use rt::comm::*;
132132
use rt::test::*;

branches/dist-snap/src/libstd/std.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -140,7 +140,6 @@ pub mod borrow;
140140
pub mod from_str;
141141
#[path = "num/num.rs"]
142142
pub mod num;
143-
pub mod iter;
144143
pub mod iterator;
145144
pub mod to_str;
146145
pub mod to_bytes;
@@ -220,4 +219,3 @@ mod std {
220219
pub use fmt;
221220
pub use to_bytes;
222221
}
223-

branches/dist-snap/src/libstd/str.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ use char;
2121
use char::Char;
2222
use clone::{Clone, DeepClone};
2323
use container::{Container, Mutable};
24-
use iter::Times;
24+
use num::Times;
2525
use iterator::{Iterator, FromIterator, Extendable};
2626
use iterator::{Filter, AdditiveIterator, Map};
2727
use iterator::{Invert, DoubleEndedIterator};

0 commit comments

Comments
 (0)