Skip to content

Commit 5354f5d

Browse files
committed
---
yaml --- r: 114551 b: refs/heads/master c: 8c5a8e1 h: refs/heads/master i: 114549: c01e134 114547: 674867a 114543: 9a551ca v: v3
1 parent c55d65f commit 5354f5d

File tree

12 files changed

+39
-131
lines changed

12 files changed

+39
-131
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
---
2-
refs/heads/master: 9659a509572106e4f7eaee7d87d993f56d33d8be
2+
refs/heads/master: 8c5a8e10b25fdd2e12de78f04d2f538a22776024
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: ec0258a381b88b5574e3f8ce72ae553ac3a574b7
55
refs/heads/try: 7c6c492fb2af9a85f21ff952942df3523b22fd17

trunk/configure

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -725,7 +725,6 @@ then
725725
if [ -z "$CC" ]
726726
then
727727
CFG_CC="clang"
728-
CFG_CXX="clang++"
729728
fi
730729
;;
731730
(*)

trunk/src/libcore/mem.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -160,9 +160,9 @@ pub unsafe fn overwrite<T>(dst: *mut T, src: T) {
160160
intrinsics::move_val_init(&mut *dst, src)
161161
}
162162

163-
/// Deprecated, use `overwrite` instead
163+
/// Deprecated, use move_val_init() instead
164164
#[inline]
165-
#[deprecated = "this function has been renamed to `overwrite`"]
165+
#[deprecated = "this function has been renamed to move_val_init()"]
166166
pub unsafe fn move_val_init<T>(dst: &mut T, src: T) {
167167
overwrite(dst, src)
168168
}

trunk/src/libcore/str.rs

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -692,19 +692,19 @@ pub fn is_utf16(v: &[u16]) -> bool {
692692
/// An iterator that decodes UTF-16 encoded codepoints from a vector
693693
/// of `u16`s.
694694
#[deriving(Clone)]
695-
pub struct UTF16Items<'a> {
695+
pub struct Utf16Items<'a> {
696696
iter: slice::Items<'a, u16>
697697
}
698698
/// The possibilities for values decoded from a `u16` stream.
699699
#[deriving(Eq, TotalEq, Clone, Show)]
700-
pub enum UTF16Item {
700+
pub enum Utf16Item {
701701
/// A valid codepoint.
702702
ScalarValue(char),
703703
/// An invalid surrogate without its pair.
704704
LoneSurrogate(u16)
705705
}
706706

707-
impl UTF16Item {
707+
impl Utf16Item {
708708
/// Convert `self` to a `char`, taking `LoneSurrogate`s to the
709709
/// replacement character (U+FFFD).
710710
#[inline]
@@ -716,8 +716,8 @@ impl UTF16Item {
716716
}
717717
}
718718

719-
impl<'a> Iterator<UTF16Item> for UTF16Items<'a> {
720-
fn next(&mut self) -> Option<UTF16Item> {
719+
impl<'a> Iterator<Utf16Item> for Utf16Items<'a> {
720+
fn next(&mut self) -> Option<Utf16Item> {
721721
let u = match self.iter.next() {
722722
Some(u) => *u,
723723
None => return None
@@ -781,8 +781,8 @@ impl<'a> Iterator<UTF16Item> for UTF16Items<'a> {
781781
/// ScalarValue('i'), ScalarValue('c'),
782782
/// LoneSurrogate(0xD834)]);
783783
/// ```
784-
pub fn utf16_items<'a>(v: &'a [u16]) -> UTF16Items<'a> {
785-
UTF16Items { iter : v.iter() }
784+
pub fn utf16_items<'a>(v: &'a [u16]) -> Utf16Items<'a> {
785+
Utf16Items { iter : v.iter() }
786786
}
787787

788788
/// Return a slice of `v` ending at (and not including) the first NUL

trunk/src/libgreen/context.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -270,7 +270,7 @@ fn initialize_call_frame(regs: &mut Registers, fptr: InitFn, arg: uint,
270270
type Registers = [uint, ..32];
271271

272272
#[cfg(target_arch = "mips")]
273-
fn new_regs() -> Box<Registers> { box {[0, .. 32]} }
273+
fn new_regs() -> Box<Registers> { box [0, .. 32] }
274274

275275
#[cfg(target_arch = "mips")]
276276
fn initialize_call_frame(regs: &mut Registers, fptr: InitFn, arg: uint,

trunk/src/liblibc/lib.rs

Lines changed: 0 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -2476,9 +2476,6 @@ pub mod consts {
24762476
}
24772477
pub mod posix08 {
24782478
}
2479-
#[cfg(target_arch = "arm")]
2480-
#[cfg(target_arch = "x86")]
2481-
#[cfg(target_arch = "x86_64")]
24822479
pub mod bsd44 {
24832480
use types::os::arch::c95::c_int;
24842481

@@ -2521,49 +2518,6 @@ pub mod consts {
25212518
pub static SHUT_WR: c_int = 1;
25222519
pub static SHUT_RDWR: c_int = 2;
25232520
}
2524-
#[cfg(target_arch = "mips")]
2525-
pub mod bsd44 {
2526-
use types::os::arch::c95::c_int;
2527-
2528-
pub static MADV_NORMAL : c_int = 0;
2529-
pub static MADV_RANDOM : c_int = 1;
2530-
pub static MADV_SEQUENTIAL : c_int = 2;
2531-
pub static MADV_WILLNEED : c_int = 3;
2532-
pub static MADV_DONTNEED : c_int = 4;
2533-
pub static MADV_REMOVE : c_int = 9;
2534-
pub static MADV_DONTFORK : c_int = 10;
2535-
pub static MADV_DOFORK : c_int = 11;
2536-
pub static MADV_MERGEABLE : c_int = 12;
2537-
pub static MADV_UNMERGEABLE : c_int = 13;
2538-
pub static MADV_HWPOISON : c_int = 100;
2539-
2540-
pub static AF_UNIX: c_int = 1;
2541-
pub static AF_INET: c_int = 2;
2542-
pub static AF_INET6: c_int = 10;
2543-
pub static SOCK_STREAM: c_int = 2;
2544-
pub static SOCK_DGRAM: c_int = 1;
2545-
pub static IPPROTO_TCP: c_int = 6;
2546-
pub static IPPROTO_IP: c_int = 0;
2547-
pub static IPPROTO_IPV6: c_int = 41;
2548-
pub static IP_MULTICAST_TTL: c_int = 33;
2549-
pub static IP_MULTICAST_LOOP: c_int = 34;
2550-
pub static IP_TTL: c_int = 2;
2551-
pub static IP_ADD_MEMBERSHIP: c_int = 35;
2552-
pub static IP_DROP_MEMBERSHIP: c_int = 36;
2553-
pub static IPV6_ADD_MEMBERSHIP: c_int = 20;
2554-
pub static IPV6_DROP_MEMBERSHIP: c_int = 21;
2555-
2556-
pub static TCP_NODELAY: c_int = 1;
2557-
pub static SOL_SOCKET: c_int = 65535;
2558-
pub static SO_KEEPALIVE: c_int = 8;
2559-
pub static SO_BROADCAST: c_int = 32;
2560-
pub static SO_REUSEADDR: c_int = 4;
2561-
pub static SO_ERROR: c_int = 4103;
2562-
2563-
pub static SHUT_RD: c_int = 0;
2564-
pub static SHUT_WR: c_int = 1;
2565-
pub static SHUT_RDWR: c_int = 2;
2566-
}
25672521
#[cfg(target_arch = "x86")]
25682522
#[cfg(target_arch = "x86_64")]
25692523
#[cfg(target_arch = "arm")]

trunk/src/libnative/io/c_unix.rs

Lines changed: 3 additions & 46 deletions
Original file line numberDiff line numberDiff line change
@@ -22,20 +22,15 @@ use libc;
2222
#[cfg(target_os = "macos")]
2323
#[cfg(target_os = "freebsd")]
2424
pub static FIONBIO: libc::c_ulong = 0x8004667e;
25-
#[cfg(target_os = "linux", not(target_arch = "mips"))]
25+
#[cfg(target_os = "linux")]
2626
#[cfg(target_os = "android")]
2727
pub static FIONBIO: libc::c_ulong = 0x5421;
28-
#[cfg(target_os = "linux", target_arch = "mips")]
29-
pub static FIONBIO: libc::c_ulong = 0x667e;
30-
3128
#[cfg(target_os = "macos")]
3229
#[cfg(target_os = "freebsd")]
3330
pub static FIOCLEX: libc::c_ulong = 0x20006601;
34-
#[cfg(target_os = "linux", not(target_arch = "mips"))]
31+
#[cfg(target_os = "linux")]
3532
#[cfg(target_os = "android")]
3633
pub static FIOCLEX: libc::c_ulong = 0x5451;
37-
#[cfg(target_os = "linux", target_arch = "mips")]
38-
pub static FIOCLEX: libc::c_ulong = 0x6601;
3934

4035
#[cfg(target_os = "macos")]
4136
#[cfg(target_os = "freebsd")]
@@ -105,7 +100,7 @@ mod select {
105100
}
106101
}
107102

108-
#[cfg(target_os = "linux", not(target_arch = "mips"))]
103+
#[cfg(target_os = "linux")]
109104
#[cfg(target_os = "android")]
110105
mod signal {
111106
use libc;
@@ -148,44 +143,6 @@ mod signal {
148143
}
149144
}
150145

151-
#[cfg(target_os = "linux", target_arch = "mips")]
152-
mod signal {
153-
use libc;
154-
155-
pub static SA_NOCLDSTOP: libc::c_ulong = 0x00000001;
156-
pub static SA_NOCLDWAIT: libc::c_ulong = 0x00010000;
157-
pub static SA_NODEFER: libc::c_ulong = 0x40000000;
158-
pub static SA_ONSTACK: libc::c_ulong = 0x08000000;
159-
pub static SA_RESETHAND: libc::c_ulong = 0x80000000;
160-
pub static SA_RESTART: libc::c_ulong = 0x10000000;
161-
pub static SA_SIGINFO: libc::c_ulong = 0x00000008;
162-
pub static SIGCHLD: libc::c_int = 18;
163-
164-
// This definition is not as accurate as it could be, {pid, uid, status} is
165-
// actually a giant union. Currently we're only interested in these fields,
166-
// however.
167-
pub struct siginfo {
168-
si_signo: libc::c_int,
169-
si_code: libc::c_int,
170-
si_errno: libc::c_int,
171-
pub pid: libc::pid_t,
172-
pub uid: libc::uid_t,
173-
pub status: libc::c_int,
174-
}
175-
176-
pub struct sigaction {
177-
pub sa_flags: libc::c_uint,
178-
pub sa_handler: extern fn(libc::c_int),
179-
pub sa_mask: sigset_t,
180-
sa_restorer: *mut libc::c_void,
181-
sa_resv: [libc::c_int, ..1],
182-
}
183-
184-
pub struct sigset_t {
185-
__val: [libc::c_ulong, ..32],
186-
}
187-
}
188-
189146
#[cfg(target_os = "macos")]
190147
#[cfg(target_os = "freebsd")]
191148
mod signal {

trunk/src/libnative/io/net.rs

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -42,12 +42,11 @@ enum InAddr {
4242
fn ip_to_inaddr(ip: ip::IpAddr) -> InAddr {
4343
match ip {
4444
ip::Ipv4Addr(a, b, c, d) => {
45-
let ip = (a as u32 << 24) |
46-
(b as u32 << 16) |
47-
(c as u32 << 8) |
48-
(d as u32 << 0);
4945
InAddr(libc::in_addr {
50-
s_addr: mem::from_be32(ip)
46+
s_addr: (d as u32 << 24) |
47+
(c as u32 << 16) |
48+
(b as u32 << 8) |
49+
(a as u32 << 0)
5150
})
5251
}
5352
ip::Ipv6Addr(a, b, c, d, e, f, g, h) => {
@@ -175,11 +174,11 @@ pub fn sockaddr_to_addr(storage: &libc::sockaddr_storage,
175174
let storage: &libc::sockaddr_in = unsafe {
176175
mem::transmute(storage)
177176
};
178-
let ip = mem::to_be32(storage.sin_addr.s_addr as u32);
179-
let a = (ip >> 24) as u8;
180-
let b = (ip >> 16) as u8;
181-
let c = (ip >> 8) as u8;
182-
let d = (ip >> 0) as u8;
177+
let addr = storage.sin_addr.s_addr as u32;
178+
let a = (addr >> 0) as u8;
179+
let b = (addr >> 8) as u8;
180+
let c = (addr >> 16) as u8;
181+
let d = (addr >> 24) as u8;
183182
Ok(ip::SocketAddr {
184183
ip: ip::Ipv4Addr(a, b, c, d),
185184
port: ntohs(storage.sin_port),

trunk/src/librustdoc/html/render.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1094,10 +1094,10 @@ impl<'a> Item<'a> {
10941094
let path = cache.external_paths.get(&self.item.def_id);
10951095
let root = match *cache.extern_locations.get(&self.item.def_id.krate) {
10961096
Remote(ref s) => s.to_string(),
1097-
Local => self.cx.root_path.clone(),
1097+
Local => format!("{}/..", self.cx.root_path),
10981098
Unknown => return None,
10991099
};
1100-
Some(format!("{root}{path}/{file}?gotosrc={goto}",
1100+
Some(format!("{root}/{path}/{file}?gotosrc={goto}",
11011101
root = root,
11021102
path = path.slice_to(path.len() - 1).connect("/"),
11031103
file = item_path(self.item),

trunk/src/librustuv/net.rs

Lines changed: 9 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -43,11 +43,11 @@ pub fn sockaddr_to_addr(storage: &libc::sockaddr_storage,
4343
let storage: &libc::sockaddr_in = unsafe {
4444
mem::transmute(storage)
4545
};
46-
let ip = mem::to_be32(storage.sin_addr.s_addr as u32);
47-
let a = (ip >> 24) as u8;
48-
let b = (ip >> 16) as u8;
49-
let c = (ip >> 8) as u8;
50-
let d = (ip >> 0) as u8;
46+
let addr = storage.sin_addr.s_addr as u32;
47+
let a = (addr >> 0) as u8;
48+
let b = (addr >> 8) as u8;
49+
let c = (addr >> 16) as u8;
50+
let d = (addr >> 24) as u8;
5151
ip::SocketAddr {
5252
ip: ip::Ipv4Addr(a, b, c, d),
5353
port: ntohs(storage.sin_port),
@@ -82,16 +82,15 @@ fn addr_to_sockaddr(addr: ip::SocketAddr) -> (libc::sockaddr_storage, uint) {
8282
let mut storage: libc::sockaddr_storage = mem::zeroed();
8383
let len = match addr.ip {
8484
ip::Ipv4Addr(a, b, c, d) => {
85-
let ip = (a as u32 << 24) |
86-
(b as u32 << 16) |
87-
(c as u32 << 8) |
88-
(d as u32 << 0);
8985
let storage: &mut libc::sockaddr_in =
9086
mem::transmute(&mut storage);
9187
(*storage).sin_family = libc::AF_INET as libc::sa_family_t;
9288
(*storage).sin_port = htons(addr.port);
9389
(*storage).sin_addr = libc::in_addr {
94-
s_addr: mem::from_be32(ip)
90+
s_addr: (d as u32 << 24) |
91+
(c as u32 << 16) |
92+
(b as u32 << 8) |
93+
(a as u32 << 0)
9594
};
9695
mem::size_of::<libc::sockaddr_in>()
9796
}

trunk/src/libstd/macros.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -331,11 +331,11 @@ macro_rules! vec(
331331
)
332332

333333

334-
/// A macro to select an event from a number of receivers.
334+
/// A macro to select an event from a number of ports.
335335
///
336336
/// This macro is used to wait for the first event to occur on a number of
337-
/// receivers. It places no restrictions on the types of receivers given to
338-
/// this macro, this can be viewed as a heterogeneous select.
337+
/// ports. It places no restrictions on the types of ports given to this macro,
338+
/// this can be viewed as a heterogeneous select.
339339
///
340340
/// # Example
341341
///

trunk/src/libstd/str.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -86,8 +86,8 @@ use vec::Vec;
8686
pub use core::str::{from_utf8, CharEq, Chars, CharOffsets};
8787
pub use core::str::{Bytes, CharSplits};
8888
pub use core::str::{CharSplitsN, Words, AnyLines, MatchIndices, StrSplits};
89-
pub use core::str::{eq_slice, is_utf8, is_utf16, UTF16Items};
90-
pub use core::str::{UTF16Item, ScalarValue, LoneSurrogate, utf16_items};
89+
pub use core::str::{eq_slice, is_utf8, is_utf16, Utf16Items};
90+
pub use core::str::{Utf16Item, ScalarValue, LoneSurrogate, utf16_items};
9191
pub use core::str::{truncate_utf16_at_nul, utf8_char_width, CharRange};
9292
pub use core::str::{Str, StrSlice};
9393

0 commit comments

Comments
 (0)