Skip to content

Commit 9169c4a

Browse files
committed
---
yaml --- r: 59050 b: refs/heads/incoming c: 24ef88c h: refs/heads/master v: v3
1 parent 4745727 commit 9169c4a

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

105 files changed

+611
-899
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ refs/heads/try: c50a9d5b664478e533ba1d1d353213d70c8ad589
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
9-
refs/heads/incoming: fdf601eaf3f6fcc727819f8c0ae2b44b30770a8a
9+
refs/heads/incoming: 24ef88cee96de837370ec370ed4d1f3aa3530a20
1010
refs/heads/dist-snap: 00dbbd01c2aee72982b3e0f9511ae1d4428c3ba9
1111
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1212
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503

branches/incoming/mk/platform.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -247,12 +247,12 @@ AR_mips-unknown-linux-gnu=mips-linux-gnu-ar
247247
CFG_LIB_NAME_mips-unknown-linux-gnu=lib$(1).so
248248
CFG_LIB_GLOB_mips-unknown-linux-gnu=lib$(1)-*.so
249249
CFG_LIB_DSYM_GLOB_mips-unknown-linux-gnu=lib$(1)-*.dylib.dSYM
250-
CFG_GCCISH_CFLAGS_mips-unknown-linux-gnu := -Wall -g -fPIC -mips32r2 -msoft-float -mabi=32 -mno-compact-eh
250+
CFG_GCCISH_CFLAGS_mips-unknown-linux-gnu := -Wall -g -fPIC -mips32r2 -msoft-float -mabi=32
251251
CFG_GCCISH_CXXFLAGS_mips-unknown-linux-gnu := -fno-rtti
252252
CFG_GCCISH_LINK_FLAGS_mips-unknown-linux-gnu := -shared -fPIC -g -mips32r2 -msoft-float -mabi=32
253253
CFG_GCCISH_DEF_FLAG_mips-unknown-linux-gnu := -Wl,--export-dynamic,--dynamic-list=
254254
CFG_GCCISH_PRE_LIB_FLAGS_mips-unknown-linux-gnu := -Wl,-whole-archive
255-
CFG_GCCISH_POST_LIB_FLAGS_mips-unknown-linux-gnu := -Wl,-no-whole-archive
255+
CFG_GCCISH_POST_LIB_FLAGS_mips-unknown-linux-gnu := -Wl,-no-whole-archive -Wl,-znoexecstack
256256
CFG_DEF_SUFFIX_mips-unknown-linux-gnu := .linux.def
257257
CFG_INSTALL_NAME_mips-unknown-linux-gnu =
258258
CFG_LIBUV_LINK_FLAGS_mips-unknown-linux-gnu =

branches/incoming/src/compiletest/header.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -91,7 +91,7 @@ pub fn is_test_ignored(config: config, testfile: &Path) -> bool {
9191
return false;
9292

9393
fn xfail_target() -> ~str {
94-
~"xfail-" + str::from_slice(os::SYSNAME)
94+
~"xfail-" + str::to_owned(os::SYSNAME)
9595
}
9696
}
9797

branches/incoming/src/compiletest/runtest.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -371,7 +371,7 @@ fn check_expected_errors(expected_errors: ~[errors::ExpectedError],
371371
was_expected = true;
372372
}
373373

374-
if !was_expected && is_compiler_error_or_warning(str::from_slice(line)) {
374+
if !was_expected && is_compiler_error_or_warning(str::to_owned(line)) {
375375
fatal_ProcRes(fmt!("unexpected compiler error or warning: '%s'",
376376
line),
377377
ProcRes);
@@ -596,7 +596,7 @@ fn make_lib_name(config: config, auxfile: &Path, testfile: &Path) -> Path {
596596

597597
fn make_exe_name(config: config, testfile: &Path) -> Path {
598598
Path(output_base_name(config, testfile).to_str() +
599-
str::from_slice(os::EXE_SUFFIX))
599+
str::to_owned(os::EXE_SUFFIX))
600600
}
601601

602602
fn make_run_args(config: config, _props: TestProps, testfile: &Path) ->

branches/incoming/src/libcore/condition.rs

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

1313
use prelude::*;
1414
use task;
15-
use local_data::{local_data_pop, local_data_set};
15+
use task::local_data::{local_data_pop, local_data_set};
1616

1717
// helper for transmutation, shown below.
1818
type RustClosure = (int, int);
@@ -24,14 +24,14 @@ pub struct Handler<T, U> {
2424

2525
pub struct Condition<'self, T, U> {
2626
name: &'static str,
27-
key: local_data::LocalDataKey<'self, Handler<T, U>>
27+
key: task::local_data::LocalDataKey<'self, Handler<T, U>>
2828
}
2929

3030
pub impl<'self, T, U> Condition<'self, T, U> {
3131
fn trap(&'self self, h: &'self fn(T) -> U) -> Trap<'self, T, U> {
3232
unsafe {
3333
let p : *RustClosure = ::cast::transmute(&h);
34-
let prev = local_data::local_data_get(self.key);
34+
let prev = task::local_data::local_data_get(self.key);
3535
let h = @Handler { handle: *p, prev: prev };
3636
Trap { cond: self, handler: h }
3737
}

branches/incoming/src/libcore/core.rc

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,6 @@ pub mod trie;
215215
pub mod task;
216216
pub mod comm;
217217
pub mod pipes;
218-
pub mod local_data;
219218

220219

221220
/* Runtime and platform support */

branches/incoming/src/libcore/io.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -711,7 +711,7 @@ impl<T:Reader> ReaderUtil for T {
711711
fn read_lines(&self) -> ~[~str] {
712712
do vec::build |push| {
713713
for self.each_line |line| {
714-
push(str::from_slice(line));
714+
push(str::to_owned(line));
715715
}
716716
}
717717
}

branches/incoming/src/libcore/libc.rs

Lines changed: 1 addition & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -268,17 +268,14 @@ pub mod types {
268268
pub type ssize_t = i32;
269269
}
270270
pub mod posix01 {
271-
use libc::types::os::arch::c95::{c_short, c_long, c_ulong, time_t};
271+
use libc::types::os::arch::c95::{c_short, c_long, time_t};
272272
use libc::types::os::arch::posix88::{dev_t, gid_t, ino_t};
273273
use libc::types::os::arch::posix88::{mode_t, off_t};
274274
use libc::types::os::arch::posix88::{uid_t};
275275

276276
pub type nlink_t = u32;
277277
pub type blksize_t = i32;
278278
pub type blkcnt_t = i32;
279-
280-
#[cfg(target_arch = "x86")]
281-
#[cfg(target_arch = "arm")]
282279
pub struct stat {
283280
st_dev: dev_t,
284281
__pad1: c_short,
@@ -301,30 +298,6 @@ pub mod types {
301298
__unused4: c_long,
302299
__unused5: c_long,
303300
}
304-
305-
#[cfg(target_arch = "mips")]
306-
pub struct stat {
307-
st_dev: c_ulong,
308-
st_pad1: [c_long, ..3],
309-
st_ino: ino_t,
310-
st_mode: mode_t,
311-
st_nlink: nlink_t,
312-
st_uid: uid_t,
313-
st_gid: gid_t,
314-
st_rdev: c_ulong,
315-
st_pad2: [c_long, ..2],
316-
st_size: off_t,
317-
st_pad3: c_long,
318-
st_atime: time_t,
319-
st_atime_nsec: c_long,
320-
st_mtime: time_t,
321-
st_mtime_nsec: c_long,
322-
st_ctime: time_t,
323-
st_ctime_nsec: c_long,
324-
st_blksize: blksize_t,
325-
st_blocks: blkcnt_t,
326-
st_pad5: [c_long, ..14],
327-
}
328301
}
329302
pub mod posix08 {}
330303
pub mod bsd44 {}
@@ -990,9 +963,6 @@ pub mod consts {
990963
}
991964
pub mod c99 {
992965
}
993-
#[cfg(target_arch = "x86")]
994-
#[cfg(target_arch = "x86_64")]
995-
#[cfg(target_arch = "arm")]
996966
pub mod posix88 {
997967
pub static O_RDONLY : int = 0;
998968
pub static O_WRONLY : int = 1;
@@ -1037,51 +1007,6 @@ pub mod consts {
10371007
pub static SIGALRM : int = 14;
10381008
pub static SIGTERM : int = 15;
10391009
}
1040-
#[cfg(target_arch = "mips")]
1041-
pub mod posix88 {
1042-
pub static O_RDONLY : int = 0;
1043-
pub static O_WRONLY : int = 1;
1044-
pub static O_RDWR : int = 2;
1045-
pub static O_APPEND : int = 8;
1046-
pub static O_CREAT : int = 256;
1047-
pub static O_EXCL : int = 1024;
1048-
pub static O_TRUNC : int = 512;
1049-
pub static S_IFIFO : int = 4096;
1050-
pub static S_IFCHR : int = 8192;
1051-
pub static S_IFBLK : int = 24576;
1052-
pub static S_IFDIR : int = 16384;
1053-
pub static S_IFREG : int = 32768;
1054-
pub static S_IFMT : int = 61440;
1055-
pub static S_IEXEC : int = 64;
1056-
pub static S_IWRITE : int = 128;
1057-
pub static S_IREAD : int = 256;
1058-
pub static S_IRWXU : int = 448;
1059-
pub static S_IXUSR : int = 64;
1060-
pub static S_IWUSR : int = 128;
1061-
pub static S_IRUSR : int = 256;
1062-
pub static F_OK : int = 0;
1063-
pub static R_OK : int = 4;
1064-
pub static W_OK : int = 2;
1065-
pub static X_OK : int = 1;
1066-
pub static STDIN_FILENO : int = 0;
1067-
pub static STDOUT_FILENO : int = 1;
1068-
pub static STDERR_FILENO : int = 2;
1069-
pub static F_LOCK : int = 1;
1070-
pub static F_TEST : int = 3;
1071-
pub static F_TLOCK : int = 2;
1072-
pub static F_ULOCK : int = 0;
1073-
pub static SIGHUP : int = 1;
1074-
pub static SIGINT : int = 2;
1075-
pub static SIGQUIT : int = 3;
1076-
pub static SIGILL : int = 4;
1077-
pub static SIGABRT : int = 6;
1078-
pub static SIGFPE : int = 8;
1079-
pub static SIGKILL : int = 9;
1080-
pub static SIGSEGV : int = 11;
1081-
pub static SIGPIPE : int = 13;
1082-
pub static SIGALRM : int = 14;
1083-
pub static SIGTERM : int = 15;
1084-
}
10851010
pub mod posix01 {
10861011
pub static SIGTRAP : int = 5;
10871012

@@ -1101,20 +1026,11 @@ pub mod consts {
11011026
}
11021027
pub mod bsd44 {
11031028
}
1104-
#[cfg(target_arch = "x86")]
1105-
#[cfg(target_arch = "x86_64")]
1106-
#[cfg(target_arch = "arm")]
11071029
pub mod extra {
11081030
pub static O_RSYNC : int = 1052672;
11091031
pub static O_DSYNC : int = 4096;
11101032
pub static O_SYNC : int = 1052672;
11111033
}
1112-
#[cfg(target_arch = "mips")]
1113-
pub mod extra {
1114-
pub static O_RSYNC : int = 16400;
1115-
pub static O_DSYNC : int = 16;
1116-
pub static O_SYNC : int = 16400;
1117-
}
11181034
}
11191035

11201036
#[cfg(target_os = "freebsd")]

branches/incoming/src/libcore/os.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -396,8 +396,8 @@ fn dup2(src: c_int, dst: c_int) -> c_int {
396396

397397

398398
pub fn dll_filename(base: &str) -> ~str {
399-
return str::from_slice(DLL_PREFIX) + str::from_slice(base) +
400-
str::from_slice(DLL_SUFFIX)
399+
return str::to_owned(DLL_PREFIX) + str::to_owned(base) +
400+
str::to_owned(DLL_SUFFIX)
401401
}
402402

403403

@@ -1208,7 +1208,7 @@ fn overridden_arg_key(_v: @OverriddenArgs) {}
12081208
12091209
pub fn args() -> ~[~str] {
12101210
unsafe {
1211-
match local_data::local_data_get(overridden_arg_key) {
1211+
match task::local_data::local_data_get(overridden_arg_key) {
12121212
None => real_args(),
12131213
Some(args) => copy args.val
12141214
}
@@ -1218,7 +1218,7 @@ pub fn args() -> ~[~str] {
12181218
pub fn set_args(new_args: ~[~str]) {
12191219
unsafe {
12201220
let overridden_args = @OverriddenArgs { val: copy new_args };
1221-
local_data::local_data_set(overridden_arg_key, overridden_args);
1221+
task::local_data::local_data_set(overridden_arg_key, overridden_args);
12221222
}
12231223
}
12241224

branches/incoming/src/libcore/path.rs

Lines changed: 9 additions & 38 deletions
Original file line numberDiff line numberDiff line change
@@ -122,6 +122,7 @@ pub trait GenericPath {
122122
mod stat {
123123
#[cfg(target_arch = "x86")]
124124
#[cfg(target_arch = "arm")]
125+
#[cfg(target_arch = "mips")]
125126
pub mod arch {
126127
use libc;
127128

@@ -151,36 +152,6 @@ mod stat {
151152
}
152153
}
153154

154-
#[cfg(target_arch = "mips")]
155-
pub mod arch {
156-
use libc;
157-
158-
pub fn default_stat() -> libc::stat {
159-
libc::stat {
160-
st_dev: 0,
161-
st_pad1: [0, ..3],
162-
st_ino: 0,
163-
st_mode: 0,
164-
st_nlink: 0,
165-
st_uid: 0,
166-
st_gid: 0,
167-
st_rdev: 0,
168-
st_pad2: [0, ..2],
169-
st_size: 0,
170-
st_pad3: 0,
171-
st_atime: 0,
172-
st_atime_nsec: 0,
173-
st_mtime: 0,
174-
st_mtime_nsec: 0,
175-
st_ctime: 0,
176-
st_ctime_nsec: 0,
177-
st_blksize: 0,
178-
st_blocks: 0,
179-
st_pad5: [0, ..14],
180-
}
181-
}
182-
}
183-
184155
#[cfg(target_arch = "x86_64")]
185156
pub mod arch {
186157
use libc;
@@ -506,7 +477,7 @@ impl GenericPath for PosixPath {
506477
fn with_filestem(&self, s: &str) -> PosixPath {
507478
match self.filetype() {
508479
None => self.with_filename(s),
509-
Some(ref t) => self.with_filename(str::from_slice(s) + *t)
480+
Some(ref t) => self.with_filename(str::to_owned(s) + *t)
510481
}
511482
}
512483

@@ -517,7 +488,7 @@ impl GenericPath for PosixPath {
517488
Some(ref s) => self.with_filename(*s)
518489
}
519490
} else {
520-
let t = ~"." + str::from_slice(t);
491+
let t = ~"." + str::to_owned(t);
521492
match self.filestem() {
522493
None => self.with_filename(t),
523494
Some(ref s) => self.with_filename(*s + t)
@@ -650,7 +621,7 @@ impl GenericPath for WindowsPath {
650621
None => {
651622
host = None;
652623
device = None;
653-
rest = str::from_slice(s);
624+
rest = str::to_owned(s);
654625
}
655626
}
656627
}
@@ -723,7 +694,7 @@ impl GenericPath for WindowsPath {
723694
fn with_filestem(&self, s: &str) -> WindowsPath {
724695
match self.filetype() {
725696
None => self.with_filename(s),
726-
Some(ref t) => self.with_filename(str::from_slice(s) + *t)
697+
Some(ref t) => self.with_filename(str::to_owned(s) + *t)
727698
}
728699
}
729700

@@ -734,7 +705,7 @@ impl GenericPath for WindowsPath {
734705
Some(ref s) => self.with_filename(*s)
735706
}
736707
} else {
737-
let t = ~"." + str::from_slice(t);
708+
let t = ~"." + str::to_owned(t);
738709
match self.filestem() {
739710
None => self.with_filename(t),
740711
Some(ref s) =>
@@ -985,7 +956,7 @@ mod tests {
985956
fn test_posix_paths() {
986957
fn t(wp: &PosixPath, s: &str) {
987958
let ss = wp.to_str();
988-
let sss = str::from_slice(s);
959+
let sss = str::to_owned(s);
989960
if (ss != sss) {
990961
debug!("got %s", ss);
991962
debug!("expected %s", sss);
@@ -1043,7 +1014,7 @@ mod tests {
10431014
fn test_normalize() {
10441015
fn t(wp: &PosixPath, s: &str) {
10451016
let ss = wp.to_str();
1046-
let sss = str::from_slice(s);
1017+
let sss = str::to_owned(s);
10471018
if (ss != sss) {
10481019
debug!("got %s", ss);
10491020
debug!("expected %s", sss);
@@ -1106,7 +1077,7 @@ mod tests {
11061077
fn test_windows_paths() {
11071078
fn t(wp: &WindowsPath, s: &str) {
11081079
let ss = wp.to_str();
1109-
let sss = str::from_slice(s);
1080+
let sss = str::to_owned(s);
11101081
if (ss != sss) {
11111082
debug!("got %s", ss);
11121083
debug!("expected %s", sss);

branches/incoming/src/libcore/prelude.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,6 @@ pub use io;
8181
pub use iter;
8282
pub use old_iter;
8383
pub use libc;
84-
pub use local_data;
8584
pub use num;
8685
pub use ops;
8786
pub use option;

0 commit comments

Comments
 (0)