Skip to content

Commit 5b40cce

Browse files
committed
---
yaml --- r: 139130 b: refs/heads/try2 c: 9814d0d h: refs/heads/master v: v3
1 parent e86d570 commit 5b40cce

File tree

21 files changed

+369
-155
lines changed

21 files changed

+369
-155
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ refs/heads/snap-stage3: 78a7676898d9f80ab540c6df5d4c9ce35bb50463
55
refs/heads/try: 519addf6277dbafccbb4159db4b710c37eaa2ec5
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
8-
refs/heads/try2: 257ef26bf11625ea8344f1251ea1877842425b64
8+
refs/heads/try2: 9814d0d4128b07d4c40dc721c977f9216fd55e91
99
refs/heads/dist-snap: ba4081a5a8573875fed17545846f6f6902c8ba8d
1010
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1111
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/try2/src/libcore/comm.rs

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@ pub fn stream<T:Owned>() -> (Port<T>, Chan<T>) {
110110
// required.
111111
#[cfg(stage1)]
112112
#[cfg(stage2)]
113+
#[cfg(stage3)]
113114
pub impl<T: Owned> Chan<T> {
114115
fn send(&self, x: T) { chan_send(self, x) }
115116
fn try_send(&self, x: T) -> bool { chan_try_send(self, x) }
@@ -149,6 +150,7 @@ fn chan_try_send<T:Owned>(self: &Chan<T>, x: T) -> bool {
149150
// Use an inherent impl so that imports are not required:
150151
#[cfg(stage1)]
151152
#[cfg(stage2)]
153+
#[cfg(stage3)]
152154
pub impl<T: Owned> Port<T> {
153155
fn recv(&self) -> T { port_recv(self) }
154156
fn try_recv(&self) -> Option<T> { port_try_recv(self) }
@@ -226,6 +228,7 @@ pub fn PortSet<T: Owned>() -> PortSet<T>{
226228
// Use an inherent impl so that imports are not required:
227229
#[cfg(stage1)]
228230
#[cfg(stage2)]
231+
#[cfg(stage3)]
229232
pub impl<T:Owned> PortSet<T> {
230233
fn recv(&self) -> T { port_set_recv(self) }
231234
fn try_recv(&self) -> Option<T> { port_set_try_recv(self) }
@@ -301,6 +304,7 @@ pub type SharedChan<T> = unstable::Exclusive<Chan<T>>;
301304
302305
#[cfg(stage1)]
303306
#[cfg(stage2)]
307+
#[cfg(stage3)]
304308
pub impl<T: Owned> SharedChan<T> {
305309
fn send(&self, x: T) { shared_chan_send(self, x) }
306310
fn try_send(&self, x: T) -> bool { shared_chan_try_send(self, x) }

branches/try2/src/libcore/io.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,9 @@ use libc;
2121
use libc::{c_int, c_long, c_uint, c_void, size_t, ssize_t};
2222
use libc::consts::os::posix88::*;
2323
use os;
24-
use prelude::*;
24+
use cast;
25+
use path::Path;
26+
use ops::Drop;
2527
use ptr;
2628
use result;
2729
use str;
@@ -75,6 +77,7 @@ pub trait Reader {
7577

7678
#[cfg(stage1)]
7779
#[cfg(stage2)]
80+
#[cfg(stage3)]
7881
impl Reader for @Reader {
7982
fn read(&self, bytes: &mut [u8], len: uint) -> uint {
8083
self.read(bytes, len)
@@ -657,6 +660,7 @@ pub trait Writer {
657660
658661
#[cfg(stage1)]
659662
#[cfg(stage2)]
663+
#[cfg(stage3)]
660664
impl Writer for @Writer {
661665
fn write(&self, v: &[const u8]) { self.write(v) }
662666
fn seek(&self, a: int, b: SeekStyle) { self.seek(a, b) }
@@ -986,7 +990,7 @@ pub trait WriterUtil {
986990

987991
impl<T:Writer> WriterUtil for T {
988992
fn write_char(&self, ch: char) {
989-
if ch as uint < 128u {
993+
if (ch as uint) < 128u {
990994
self.write(&[ch as u8]);
991995
} else {
992996
self.write_str(str::from_char(ch));

branches/try2/src/libcore/num/strconv.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ pub pure fn to_str_bytes_common<T:NumCast+Zero+One+Eq+Ord+NumStrConv+Copy+
165165
Div<T,T>+Neg<T>+Modulo<T,T>+Mul<T,T>>(
166166
num: &T, radix: uint, negative_zero: bool,
167167
sign: SignFormat, digits: SignificantDigits) -> (~[u8], bool) {
168-
if radix as int < 2 {
168+
if (radix as int) < 2 {
169169
fail!(fmt!("to_str_bytes_common: radix %? to low, \
170170
must lie in the range [2, 36]", radix));
171171
} else if radix as int > 36 {
@@ -455,10 +455,10 @@ pub pure fn from_str_bytes_common<T:NumCast+Zero+One+Ord+Copy+Div<T,T>+
455455
_ if special && radix >= DIGIT_I_RADIX // first digit of 'inf'
456456
=> fail!(fmt!("from_str_bytes_common: radix %? incompatible with \
457457
special values 'inf' and 'NaN'", radix)),
458-
_ if radix as int < 2
458+
_ if (radix as int) < 2
459459
=> fail!(fmt!("from_str_bytes_common: radix %? to low, \
460460
must lie in the range [2, 36]", radix)),
461-
_ if radix as int > 36
461+
_ if (radix as int) > 36
462462
=> fail!(fmt!("from_str_bytes_common: radix %? to high, \
463463
must lie in the range [2, 36]", radix)),
464464
_ => ()

branches/try2/src/libcore/prelude.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -43,6 +43,7 @@ pub use tuple::{CopyableTuple, ImmutableTuple, ExtendedTupleOps};
4343
pub use vec::{CopyableVector, ImmutableVector};
4444
pub use vec::{ImmutableEqVector, ImmutableCopyableVector};
4545
pub use vec::{OwnedVector, OwnedCopyableVector};
46+
pub use io::{Reader, ReaderUtil, Writer, WriterUtil};
4647

4748
/* Reexported runtime types */
4849
pub use comm::{stream, Port, Chan, GenericChan, GenericSmartChan, GenericPort, Peekable};

branches/try2/src/libcore/repr.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -218,7 +218,7 @@ pub impl ReprVisitor {
218218

219219
fn write_escaped_slice(&self, slice: &str) {
220220
self.writer.write_char('"');
221-
for str::chars_each(slice) |ch| {
221+
for slice.each_char |ch| {
222222
self.writer.write_escaped_char(ch);
223223
}
224224
self.writer.write_char('"');
@@ -242,7 +242,7 @@ pub impl ReprVisitor {
242242
let (sz, al) = unsafe { ((*inner).size, (*inner).align) };
243243
self.writer.write_char('[');
244244
let mut first = true;
245-
while p as uint < end as uint {
245+
while (p as uint) < (end as uint) {
246246
if first {
247247
first = false;
248248
} else {

0 commit comments

Comments
 (0)