Skip to content

Commit a9fbf6f

Browse files
committed
---
yaml --- r: 80777 b: refs/heads/try c: f39ab75 h: refs/heads/master i: 80775: b53419d v: v3
1 parent 00e91f2 commit a9fbf6f

Some content is hidden

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

92 files changed

+928
-1961
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
refs/heads/master: 4c6bf4872012c010f84dc7fa2cdfe87522533f89
33
refs/heads/snap-stage1: e33de59e47c5076a89eadeb38f4934f58a3618a6
44
refs/heads/snap-stage3: cbd1eefbd350797b783df119fed7956d7e1c74ad
5-
refs/heads/try: 9792ec6da72ff2bac2c8624c8ad433ed708774e4
5+
refs/heads/try: f39ab75a782a89f5e2bdf85c5fedc7991094ec72
66
refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c

branches/try/doc/rust.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1717,8 +1717,7 @@ Supported traits for `deriving` are:
17171717
* `Clone` and `DeepClone`, to perform (deep) copies.
17181718
* `IterBytes`, to iterate over the bytes in a data type.
17191719
* `Rand`, to create a random instance of a data type.
1720-
* `Default`, to create an empty instance of a data type.
1721-
* `Zero`, to create an zero instance of a numeric data type.
1720+
* `Zero`, to create an zero (or empty) instance of a data type.
17221721
* `ToStr`, to convert to a string. For a type with this instance,
17231722
`obj.to_str()` has similar output as `fmt!("%?", obj)`, but it differs in that
17241723
each constituent field of the type must also implement `ToStr` and will have

branches/try/doc/rustpkg.md

Lines changed: 9 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -52,11 +52,13 @@ A valid workspace must contain each of the following subdirectories:
5252
rustpkg will install libraries for bar to `foo/lib/x86_64-apple-darwin/`.
5353
The libraries will have names of the form `foo/lib/x86_64-apple-darwin/libbar-[hash].dylib`,
5454
where [hash] is a hash of the package ID.
55-
* 'bin/': `rustpkg install` installs executable binaries into this directory.
55+
* 'bin/': `rustpkg install` installs executable binaries into a target-specific subdirectory of this directory.
5656

57-
For example, rustpkg will install executables for `bar` to
58-
`foo/bin`.
59-
The executables will have names of the form `foo/bin/bar`.
57+
For example, on a 64-bit machine running Mac OS X,
58+
if `foo` is a workspace, containing the package `bar`,
59+
rustpkg will install executables for `bar` to
60+
`foo/bin/x86_64-apple-darwin/`.
61+
The executables will have names of the form `foo/bin/x86_64-apple-darwin/bar`.
6062
* 'build/': `rustpkg build` stores temporary build artifacts in a target-specific subdirectory of this directory.
6163

6264
For example, on a 64-bit machine running Mac OS X,
@@ -83,12 +85,6 @@ rustpkg also interprets any dependencies on such a package ID literally
8385
Thus, `github.com/mozilla/rust#5c4cd30f80` is also a valid package ID,
8486
since git can deduce that 5c4cd30f80 refers to a revision of the desired repository.
8587

86-
A package identifier can name a subdirectory of another package.
87-
For example, if `foo` is a workspace, and `foo/src/bar/lib.rs` exists,
88-
as well as `foo/src/bar/extras/baz/lib.rs`,
89-
then both `bar` and `bar/extras/baz` are valid package identifiers
90-
in the workspace `foo`.
91-
9288
## Source files
9389

9490
rustpkg searches for four different fixed filenames in order to determine the crates to build:
@@ -144,11 +140,9 @@ but not in their `lib` or `bin` directories.
144140

145141
## install
146142

147-
`rustpkg install foo` builds the libraries and/or executables that are targets for `foo`.
148-
If `RUST_PATH` is declared as an environment variable, then rustpkg installs the
149-
libraries and executables into the `lib` and `bin` subdirectories
150-
of the first entry in `RUST_PATH`.
151-
Otherwise, it installs them into `foo`'s `lib` and `bin` directories.
143+
`rustpkg install foo` builds the libraries and/or executables that are targets for `foo`,
144+
and then installs them either into `foo`'s `lib` and `bin` directories,
145+
or into the `lib` and `bin` subdirectories of the first entry in `RUST_PATH`.
152146

153147
## test
154148

branches/try/doc/tutorial.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2249,7 +2249,7 @@ enum ABC { A, B, C }
22492249

22502250
The full list of derivable traits is `Eq`, `TotalEq`, `Ord`,
22512251
`TotalOrd`, `Encodable` `Decodable`, `Clone`, `DeepClone`,
2252-
`IterBytes`, `Rand`, `Default`, `Zero`, and `ToStr`.
2252+
`IterBytes`, `Rand`, `Zero`, and `ToStr`.
22532253

22542254
# Crates and the module system
22552255

branches/try/mk/rt.mk

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,7 @@ RUNTIME_CXXS_$(1)_$(2) := \
7575
rt/rust_rng.cpp \
7676
rt/rust_upcall.cpp \
7777
rt/rust_uv.cpp \
78+
rt/rust_crate_map.cpp \
7879
rt/isaac/randport.cpp \
7980
rt/miniz.cpp \
8081
rt/memory_region.cpp \

branches/try/src/compiletest/compiletest.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -309,7 +309,7 @@ pub fn make_test_name(config: &config, testfile: &Path) -> test::TestName {
309309
let filename = path.filename();
310310
let p = path.pop();
311311
let dir = p.filename();
312-
fmt!("%s/%s", dir.unwrap_or(""), filename.unwrap_or(""))
312+
fmt!("%s/%s", dir.unwrap_or_default(""), filename.unwrap_or_default(""))
313313
}
314314

315315
test::DynTestName(fmt!("[%s] %s",

branches/try/src/libextra/fileinput.rs

Lines changed: 10 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -417,23 +417,20 @@ mod test {
417417

418418
use super::{FileInput, make_path_option_vec, input_vec, input_vec_state};
419419

420-
use std::rt::io;
421-
use std::rt::io::Writer;
422-
use std::rt::io::file;
420+
use std::io;
423421
use std::uint;
424422
use std::vec;
425423

426424
fn make_file(path : &Path, contents: &[~str]) {
427-
let mut file = file::open(path, io::CreateOrTruncate, io::Write).unwrap();
425+
let file = io::file_writer(path, [io::Create, io::Truncate]).unwrap();
428426

429427
for str in contents.iter() {
430-
file.write(str.as_bytes());
431-
file.write(['\n' as u8]);
428+
file.write_str(*str);
429+
file.write_char('\n');
432430
}
433431
}
434432

435433
#[test]
436-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
437434
fn test_make_path_option_vec() {
438435
let strs = [~"some/path",
439436
~"some/other/path"];
@@ -448,7 +445,6 @@ mod test {
448445
}
449446
450447
#[test]
451-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
452448
fn test_fileinput_read_byte() {
453449
let filenames = make_path_option_vec(vec::from_fn(
454450
3,
@@ -479,7 +475,6 @@ mod test {
479475
}
480476
481477
#[test]
482-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
483478
fn test_fileinput_read() {
484479
let filenames = make_path_option_vec(vec::from_fn(
485480
3,
@@ -500,7 +495,6 @@ mod test {
500495
}
501496

502497
#[test]
503-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
504498
fn test_input_vec() {
505499
let mut all_lines = ~[];
506500
let filenames = make_path_option_vec(vec::from_fn(
@@ -524,7 +518,6 @@ mod test {
524518
}
525519

526520
#[test]
527-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
528521
fn test_input_vec_state() {
529522
let filenames = make_path_option_vec(vec::from_fn(
530523
3,
@@ -547,7 +540,6 @@ mod test {
547540
}
548541

549542
#[test]
550-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
551543
fn test_empty_files() {
552544
let filenames = make_path_option_vec(vec::from_fn(
553545
3,
@@ -572,21 +564,18 @@ mod test {
572564
}
573565
574566
#[test]
575-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
576567
fn test_no_trailing_newline() {
577568
let f1 =
578569
Some(Path("tmp/lib-fileinput-test-no-trailing-newline-1.tmp"));
579570
let f2 =
580571
Some(Path("tmp/lib-fileinput-test-no-trailing-newline-2.tmp"));
581572
582-
{
583-
let mut wr = file::open(f1.get_ref(), io::CreateOrTruncate,
584-
io::Write).unwrap();
585-
wr.write("1\n2".as_bytes());
586-
let mut wr = file::open(f2.get_ref(), io::CreateOrTruncate,
587-
io::Write).unwrap();
588-
wr.write("3\n4".as_bytes());
589-
}
573+
let wr = io::file_writer(f1.get_ref(),
574+
[io::Create, io::Truncate]).unwrap();
575+
wr.write_str("1\n2");
576+
let wr = io::file_writer(f2.get_ref(),
577+
[io::Create, io::Truncate]).unwrap();
578+
wr.write_str("3\n4");
590579
591580
let mut lines = ~[];
592581
do input_vec(~[f1, f2]) |line| {
@@ -598,7 +587,6 @@ mod test {
598587
599588
600589
#[test]
601-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
602590
fn test_next_file() {
603591
let filenames = make_path_option_vec(vec::from_fn(
604592
3,
@@ -630,7 +618,6 @@ mod test {
630618
631619
#[test]
632620
#[should_fail]
633-
#[ignore(cfg(windows))] // FIXME(#8810): rt::io::file and windows don't agree
634621
fn test_input_vec_missing_file() {
635622
do input_vec(make_path_option_vec([~"this/file/doesnt/exist"], true)) |line| {
636623
println(line);

0 commit comments

Comments
 (0)