Skip to content

Commit 231080a

Browse files
committed
---
yaml --- r: 274403 b: refs/heads/stable c: 005c962 h: refs/heads/master i: 274401: 903ffcf 274399: 60f8f32
1 parent eab0cca commit 231080a

File tree

93 files changed

+1564
-90134
lines changed

Some content is hidden

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

93 files changed

+1564
-90134
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ refs/heads/tmp: e06d2ad9fcd5027bcaac5b08fc9aa39a49d0ecd3
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: c0221c8897db309a79990367476177b1230bb264
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828
32-
refs/heads/stable: 27380a3eddd57a65744416e308408e4f41e57f4b
32+
refs/heads/stable: 005c9624bbd1cae81b1e9185743e332e160bb5c7
3333
refs/tags/1.0.0: 55bd4f8ff2b323f317ae89e254ce87162d52a375
3434
refs/tags/1.1.0: bc3c16f09287e5545c1d3f76b7abd54f2eca868b
3535
refs/tags/1.2.0: f557861f822c34f07270347b94b5280de20a597e

branches/stable/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ and documentation.
99

1010
Read ["Installing Rust"] from [The Book].
1111

12-
["Installing Rust"]: https://doc.rust-lang.org/book/getting-started.html#installing-rust
12+
["Installing Rust"]: https://doc.rust-lang.org/book/installing-rust.html
1313
[The Book]: https://doc.rust-lang.org/book/index.html
1414

1515
## Building from Source

branches/stable/RELEASES.md

Lines changed: 0 additions & 352 deletions
Large diffs are not rendered by default.

branches/stable/configure

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -334,6 +334,14 @@ enable_if_not_disabled() {
334334
fi
335335
}
336336

337+
to_llvm_triple() {
338+
case $1 in
339+
i686-w64-mingw32) echo i686-pc-windows-gnu ;;
340+
x86_64-w64-mingw32) echo x86_64-pc-windows-gnu ;;
341+
*) echo $1 ;;
342+
esac
343+
}
344+
337345
to_gnu_triple() {
338346
case $1 in
339347
i686-pc-windows-gnu) echo i686-w64-mingw32 ;;
@@ -638,6 +646,12 @@ valopt_nosave host "${CFG_BUILD}" "GNUs ./configure syntax LLVM host triples"
638646
valopt_nosave target "${CFG_HOST}" "GNUs ./configure syntax LLVM target triples"
639647
valopt_nosave mandir "${CFG_PREFIX}/share/man" "install man pages in PATH"
640648

649+
# Temporarily support old triples until buildbots get updated
650+
CFG_BUILD=$(to_llvm_triple $CFG_BUILD)
651+
putvar CFG_BUILD # Yes, this creates a duplicate entry, but the last one wins.
652+
CFG_HOST=$(to_llvm_triple $CFG_HOST)
653+
CFG_TARGET=$(to_llvm_triple $CFG_TARGET)
654+
641655
# On Windows this determines root of the subtree for target libraries.
642656
# Host runtime libs always go to 'bin'.
643657
valopt libdir "${CFG_PREFIX}/lib" "install libraries"

branches/stable/mk/cfg/armv7-unknown-linux-gnueabihf.mk

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# armv7-unknown-linux-gnueabihf configuration
2-
CROSS_PREFIX_armv7-unknown-linux-gnueabihf=arm-linux-gnueabihf-
2+
CROSS_PREFIX_armv7-unknown-linux-gnueabihf=armv7-unknown-linux-gnueabihf-
33
CC_armv7-unknown-linux-gnueabihf=gcc
44
CXX_armv7-unknown-linux-gnueabihf=g++
55
CPP_armv7-unknown-linux-gnueabihf=gcc -E
@@ -8,8 +8,8 @@ CFG_LIB_NAME_armv7-unknown-linux-gnueabihf=lib$(1).so
88
CFG_STATIC_LIB_NAME_armv7-unknown-linux-gnueabihf=lib$(1).a
99
CFG_LIB_GLOB_armv7-unknown-linux-gnueabihf=lib$(1)-*.so
1010
CFG_LIB_DSYM_GLOB_armv7-unknown-linux-gnueabihf=lib$(1)-*.dylib.dSYM
11-
CFG_JEMALLOC_CFLAGS_armv7-unknown-linux-gnueabihf := -D__arm__ $(CFLAGS) -march=armv7
12-
CFG_GCCISH_CFLAGS_armv7-unknown-linux-gnueabihf := -Wall -g -fPIC -D__arm__ $(CFLAGS) -march=armv7
11+
CFG_JEMALLOC_CFLAGS_armv7-unknown-linux-gnueabihf := -D__arm__ $(CFLAGS)
12+
CFG_GCCISH_CFLAGS_armv7-unknown-linux-gnueabihf := -Wall -g -fPIC -D__arm__ $(CFLAGS)
1313
CFG_GCCISH_CXXFLAGS_armv7-unknown-linux-gnueabihf := -fno-rtti $(CXXFLAGS)
1414
CFG_GCCISH_LINK_FLAGS_armv7-unknown-linux-gnueabihf := -shared -fPIC -g
1515
CFG_GCCISH_DEF_FLAG_armv7-unknown-linux-gnueabihf := -Wl,--export-dynamic,--dynamic-list=

branches/stable/mk/cfg/powerpc64-unknown-linux-gnu.mk

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ CFG_LIB_NAME_powerpc64-unknown-linux-gnu=lib$(1).so
88
CFG_STATIC_LIB_NAME_powerpc64-unknown-linux-gnu=lib$(1).a
99
CFG_LIB_GLOB_powerpc64-unknown-linux-gnu=lib$(1)-*.so
1010
CFG_LIB_DSYM_GLOB_powerpc64-unknown-linux-gnu=lib$(1)-*.dylib.dSYM
11-
CFG_JEMALLOC_CFLAGS_powerpc64-unknown-linux-gnu := -m64
1211
CFG_CFLAGS_powerpc64-unknown-linux-gnu := -m64 $(CFLAGS)
1312
CFG_GCCISH_CFLAGS_powerpc64-unknown-linux-gnu := -Wall -Werror -g -fPIC -m64 $(CFLAGS)
1413
CFG_GCCISH_CXXFLAGS_powerpc64-unknown-linux-gnu := -fno-rtti $(CXXFLAGS)

branches/stable/mk/tests.mk

Lines changed: 4 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ ifdef CHECK_IGNORED
4545
TESTARGS += --ignored
4646
endif
4747

48-
# Arguments to the cfail/rfail/rpass/bench tests
48+
# Arguments to the cfail/rfail/rpass tests
4949
ifdef CFG_VALGRIND
5050
CTEST_RUNTOOL = --runtool "$(CFG_VALGRIND)"
5151
endif
@@ -306,7 +306,6 @@ check-stage$(1)-T-$(2)-H-$(3)-exec: \
306306
check-stage$(1)-T-$(2)-H-$(3)-rustdocck-exec \
307307
check-stage$(1)-T-$(2)-H-$(3)-crates-exec \
308308
check-stage$(1)-T-$(2)-H-$(3)-doc-crates-exec \
309-
check-stage$(1)-T-$(2)-H-$(3)-bench-exec \
310309
check-stage$(1)-T-$(2)-H-$(3)-debuginfo-gdb-exec \
311310
check-stage$(1)-T-$(2)-H-$(3)-debuginfo-lldb-exec \
312311
check-stage$(1)-T-$(2)-H-$(3)-codegen-exec \
@@ -344,7 +343,6 @@ check-stage$(1)-T-$(2)-H-$(3)-pretty-exec: \
344343
check-stage$(1)-T-$(2)-H-$(3)-pretty-rpass-full-exec \
345344
check-stage$(1)-T-$(2)-H-$(3)-pretty-rfail-exec \
346345
check-stage$(1)-T-$(2)-H-$(3)-pretty-rfail-full-exec \
347-
check-stage$(1)-T-$(2)-H-$(3)-pretty-bench-exec \
348346
check-stage$(1)-T-$(2)-H-$(3)-pretty-pretty-exec
349347

350348
endef
@@ -468,7 +466,6 @@ CFAIL_FULL_RS := $(wildcard $(S)src/test/compile-fail-fulldeps/*.rs)
468466
RFAIL_RS := $(wildcard $(S)src/test/run-fail/*.rs)
469467
CFAIL_RS := $(wildcard $(S)src/test/compile-fail/*.rs)
470468
PFAIL_RS := $(wildcard $(S)src/test/parse-fail/*.rs)
471-
BENCH_RS := $(wildcard $(S)src/test/bench/*.rs)
472469
PRETTY_RS := $(wildcard $(S)src/test/pretty/*.rs)
473470
DEBUGINFO_GDB_RS := $(wildcard $(S)src/test/debuginfo/*.rs)
474471
DEBUGINFO_LLDB_RS := $(wildcard $(S)src/test/debuginfo/*.rs)
@@ -485,7 +482,6 @@ CFAIL_FULL_TESTS := $(CFAIL_FULL_RS)
485482
RFAIL_TESTS := $(RFAIL_RS)
486483
CFAIL_TESTS := $(CFAIL_RS)
487484
PFAIL_TESTS := $(PFAIL_RS)
488-
BENCH_TESTS := $(BENCH_RS)
489485
PRETTY_TESTS := $(PRETTY_RS)
490486
DEBUGINFO_GDB_TESTS := $(DEBUGINFO_GDB_RS)
491487
DEBUGINFO_LLDB_TESTS := $(DEBUGINFO_LLDB_RS)
@@ -533,11 +529,6 @@ CTEST_BUILD_BASE_pfail = parse-fail
533529
CTEST_MODE_pfail = parse-fail
534530
CTEST_RUNTOOL_pfail = $(CTEST_RUNTOOL)
535531

536-
CTEST_SRC_BASE_bench = bench
537-
CTEST_BUILD_BASE_bench = bench
538-
CTEST_MODE_bench = run-pass
539-
CTEST_RUNTOOL_bench = $(CTEST_RUNTOOL)
540-
541532
CTEST_SRC_BASE_debuginfo-gdb = debuginfo
542533
CTEST_BUILD_BASE_debuginfo-gdb = debuginfo-gdb
543534
CTEST_MODE_debuginfo-gdb = debuginfo-gdb
@@ -612,7 +603,7 @@ TEST_SREQ$(1)_T_$(2)_H_$(3) = \
612603
$$(HBIN$(1)_H_$(3))/compiletest$$(X_$(3)) \
613604
$$(SREQ$(1)_T_$(2)_H_$(3))
614605

615-
# Rules for the cfail/rfail/rpass/bench test runner
606+
# Rules for the cfail/rfail/rpass test runner
616607

617608
# The tests select when to use debug configuration on their own;
618609
# remove directive, if present, from CFG_RUSTC_FLAGS (issue #7898).
@@ -675,7 +666,6 @@ CTEST_DEPS_cfail-full_$(1)-T-$(2)-H-$(3) = $$(CFAIL_FULL_TESTS) $$(CSREQ$(1)_T_$
675666
CTEST_DEPS_rfail_$(1)-T-$(2)-H-$(3) = $$(RFAIL_TESTS)
676667
CTEST_DEPS_cfail_$(1)-T-$(2)-H-$(3) = $$(CFAIL_TESTS)
677668
CTEST_DEPS_pfail_$(1)-T-$(2)-H-$(3) = $$(PFAIL_TESTS)
678-
CTEST_DEPS_bench_$(1)-T-$(2)-H-$(3) = $$(BENCH_TESTS)
679669
CTEST_DEPS_debuginfo-gdb_$(1)-T-$(2)-H-$(3) = $$(DEBUGINFO_GDB_TESTS)
680670
CTEST_DEPS_debuginfo-lldb_$(1)-T-$(2)-H-$(3) = $$(DEBUGINFO_LLDB_TESTS) \
681671
$(S)src/etc/lldb_batchmode.py \
@@ -748,7 +738,7 @@ endif
748738
endef
749739

750740
CTEST_NAMES = rpass rpass-valgrind rpass-full rfail-full cfail-full rfail cfail pfail \
751-
bench debuginfo-gdb debuginfo-lldb codegen codegen-units rustdocck
741+
debuginfo-gdb debuginfo-lldb codegen codegen-units rustdocck
752742

753743
$(foreach host,$(CFG_HOST), \
754744
$(eval $(foreach target,$(CFG_TARGET), \
@@ -757,20 +747,18 @@ $(foreach host,$(CFG_HOST), \
757747
$(eval $(call DEF_RUN_COMPILETEST,$(stage),$(target),$(host),$(name))))))))))
758748

759749
PRETTY_NAMES = pretty-rpass pretty-rpass-valgrind pretty-rpass-full pretty-rfail-full pretty-rfail \
760-
pretty-bench pretty-pretty
750+
pretty-pretty
761751
PRETTY_DEPS_pretty-rpass = $(RPASS_TESTS)
762752
PRETTY_DEPS_pretty-rpass-valgrind = $(RPASS_VALGRIND_TESTS)
763753
PRETTY_DEPS_pretty-rpass-full = $(RPASS_FULL_TESTS)
764754
PRETTY_DEPS_pretty-rfail-full = $(RFAIL_FULL_TESTS)
765755
PRETTY_DEPS_pretty-rfail = $(RFAIL_TESTS)
766-
PRETTY_DEPS_pretty-bench = $(BENCH_TESTS)
767756
PRETTY_DEPS_pretty-pretty = $(PRETTY_TESTS)
768757
PRETTY_DIRNAME_pretty-rpass = run-pass
769758
PRETTY_DIRNAME_pretty-rpass-valgrind = run-pass-valgrind
770759
PRETTY_DIRNAME_pretty-rpass-full = run-pass-fulldeps
771760
PRETTY_DIRNAME_pretty-rfail-full = run-fail-fulldeps
772761
PRETTY_DIRNAME_pretty-rfail = run-fail
773-
PRETTY_DIRNAME_pretty-bench = bench
774762
PRETTY_DIRNAME_pretty-pretty = pretty
775763

776764
define DEF_PRETTY_FULLDEPS
@@ -920,7 +908,6 @@ TEST_GROUPS = \
920908
rfail \
921909
cfail \
922910
pfail \
923-
bench \
924911
rmake \
925912
rustdocck \
926913
debuginfo-gdb \
@@ -935,7 +922,6 @@ TEST_GROUPS = \
935922
pretty-rpass-full \
936923
pretty-rfail-full \
937924
pretty-rfail \
938-
pretty-bench \
939925
pretty-pretty \
940926
$(NULL)
941927

@@ -1039,8 +1025,6 @@ $(3)/test/run-make/%-$(1)-T-$(2)-H-$(3).ok: \
10391025
export INCLUDE := $$(CFG_MSVC_INCLUDE_PATH_$$(HOST_$(3)))
10401026
$(3)/test/run-make/%-$(1)-T-$(2)-H-$(3).ok: \
10411027
export LIB := $$(CFG_MSVC_LIB_PATH_$$(HOST_$(3)))
1042-
$(3)/test/run-make/%-$(1)-T-$(2)-H-$(3).ok: \
1043-
export MSVC_LIB := "$$(CFG_MSVC_LIB_$$(HOST_$(3)))"
10441028
$(3)/test/run-make/%-$(1)-T-$(2)-H-$(3).ok: \
10451029
$(S)src/test/run-make/%/Makefile \
10461030
$$(CSREQ$(1)_T_$(2)_H_$(3))

branches/stable/src/doc/book/error-handling.md

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -265,8 +265,6 @@ fn map<F, T, A>(option: Option<T>, f: F) -> Option<A> where F: FnOnce(T) -> A {
265265
```
266266

267267
Indeed, `map` is [defined as a method][2] on `Option<T>` in the standard library.
268-
As a method, it has a slighly different signature: methods take `self`, `&self`,
269-
or `&mut self` as their first argument.
270268

271269
Armed with our new combinator, we can rewrite our `extension_explicit` method
272270
to get rid of the case analysis:
@@ -296,9 +294,6 @@ fn unwrap_or<T>(option: Option<T>, default: T) -> T {
296294
}
297295
```
298296

299-
Like with `map` above, the standard library implementation is a method instead
300-
of a free function.
301-
302297
The trick here is that the default value must have the same type as the value
303298
that might be inside the `Option<T>`. Using it is dead simple in our case:
304299

branches/stable/src/doc/book/guessing-game.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -279,7 +279,7 @@ displaying the message.
279279
[expect]: ../std/option/enum.Option.html#method.expect
280280
[panic]: error-handling.html
281281

282-
If we leave off calling this method, our program will compile, but
282+
If we leave off calling these two methods, our program will compile, but
283283
we’ll get a warning:
284284

285285
```bash
@@ -680,7 +680,7 @@ fn main() {
680680
}
681681
```
682682
683-
The new two lines:
683+
The new three lines:
684684
685685
```rust,ignore
686686
let guess: u32 = guess.trim().parse()

branches/stable/src/doc/book/testing.md

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ Cargo will automatically generate a simple test when you make a new project.
2424
Here's the contents of `src/lib.rs`:
2525

2626
```rust
27-
# fn main() {}
2827
#[test]
2928
fn it_works() {
3029
}
@@ -76,7 +75,6 @@ So why does our do-nothing test pass? Any test which doesn't `panic!` passes,
7675
and any test that does `panic!` fails. Let's make our test fail:
7776

7877
```rust
79-
# fn main() {}
8078
#[test]
8179
fn it_works() {
8280
assert!(false);
@@ -147,7 +145,6 @@ This is useful if you want to integrate `cargo test` into other tooling.
147145
We can invert our test's failure with another attribute: `should_panic`:
148146

149147
```rust
150-
# fn main() {}
151148
#[test]
152149
#[should_panic]
153150
fn it_works() {
@@ -178,7 +175,6 @@ Rust provides another macro, `assert_eq!`, that compares two arguments for
178175
equality:
179176

180177
```rust
181-
# fn main() {}
182178
#[test]
183179
#[should_panic]
184180
fn it_works() {
@@ -213,7 +209,6 @@ make sure that the failure message contains the provided text. A safer version
213209
of the example above would be:
214210

215211
```rust
216-
# fn main() {}
217212
#[test]
218213
#[should_panic(expected = "assertion failed")]
219214
fn it_works() {
@@ -224,7 +219,6 @@ fn it_works() {
224219
That's all there is to the basics! Let's write one 'real' test:
225220

226221
```rust,ignore
227-
# fn main() {}
228222
pub fn add_two(a: i32) -> i32 {
229223
a + 2
230224
}
@@ -244,7 +238,6 @@ Sometimes a few specific tests can be very time-consuming to execute. These
244238
can be disabled by default by using the `ignore` attribute:
245239

246240
```rust
247-
# fn main() {}
248241
#[test]
249242
fn it_works() {
250243
assert_eq!(4, add_two(2));
@@ -306,7 +299,6 @@ missing the `tests` module. The idiomatic way of writing our example
306299
looks like this:
307300

308301
```rust,ignore
309-
# fn main() {}
310302
pub fn add_two(a: i32) -> i32 {
311303
a + 2
312304
}
@@ -335,7 +327,6 @@ a large module, and so this is a common use of globs. Let's change our
335327
`src/lib.rs` to make use of it:
336328

337329
```rust,ignore
338-
# fn main() {}
339330
pub fn add_two(a: i32) -> i32 {
340331
a + 2
341332
}
@@ -386,7 +377,6 @@ put a `tests/lib.rs` file inside, with this as its contents:
386377
```rust,ignore
387378
extern crate adder;
388379
389-
# fn main() {}
390380
#[test]
391381
fn it_works() {
392382
assert_eq!(4, adder::add_two(2));
@@ -442,7 +432,6 @@ running examples in your documentation (**note:** this only works in library
442432
crates, not binary crates). Here's a fleshed-out `src/lib.rs` with examples:
443433

444434
```rust,ignore
445-
# fn main() {}
446435
//! The `adder` crate provides functions that add numbers to other numbers.
447436
//!
448437
//! # Examples

branches/stable/src/libcore/intrinsics.rs

Lines changed: 2 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -552,15 +552,7 @@ extern "rust-intrinsic" {
552552
pub fn discriminant_value<T>(v: &T) -> u64;
553553

554554
/// Rust's "try catch" construct which invokes the function pointer `f` with
555-
/// the data pointer `data`.
556-
///
557-
/// The third pointer is a target-specific data pointer which is filled in
558-
/// with the specifics of the exception that occurred. For examples on Unix
559-
/// platforms this is a `*mut *mut T` which is filled in by the compiler and
560-
/// on MSVC it's `*mut [usize; 2]`. For more information see the compiler's
561-
/// source as well as std's catch implementation.
562-
#[cfg(not(stage0))]
563-
pub fn try(f: fn(*mut u8), data: *mut u8, local_ptr: *mut u8) -> i32;
564-
#[cfg(stage0)]
555+
/// the data pointer `data`, returning the exception payload if an exception
556+
/// is thrown (aka the thread panics).
565557
pub fn try(f: fn(*mut u8), data: *mut u8) -> *mut u8;
566558
}

branches/stable/src/librustc_back/target/x86_64_pc_windows_msvc.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ use target::Target;
1313
pub fn target() -> Target {
1414
let mut base = super::windows_msvc_base::opts();
1515
base.cpu = "x86-64".to_string();
16+
base.custom_unwind_resume = true;
1617

1718
Target {
1819
llvm_target: "x86_64-pc-windows-msvc".to_string(),

branches/stable/src/librustc_llvm/archive_ro.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -79,14 +79,14 @@ impl Drop for ArchiveRO {
7979
}
8080

8181
impl<'a> Iterator for Iter<'a> {
82-
type Item = Result<Child<'a>, String>;
82+
type Item = Child<'a>;
8383

84-
fn next(&mut self) -> Option<Result<Child<'a>, String>> {
84+
fn next(&mut self) -> Option<Child<'a>> {
8585
let ptr = unsafe { ::LLVMRustArchiveIteratorNext(self.ptr) };
8686
if ptr.is_null() {
87-
::last_error().map(Err)
87+
None
8888
} else {
89-
Some(Ok(Child { ptr: ptr, _data: marker::PhantomData }))
89+
Some(Child { ptr: ptr, _data: marker::PhantomData })
9090
}
9191
}
9292
}

0 commit comments

Comments
 (0)