Skip to content

Commit f12006c

Browse files
---
yaml --- r: 212143 b: refs/heads/tmp c: d136714 h: refs/heads/master i: 212141: 60f75ad 212139: 226a4d4 212135: 938a395 212127: b13f3db v: v3
1 parent 9aea373 commit f12006c

36 files changed

+850
-711
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ refs/heads/building: 126db549b038c84269a1e4fe46f051b2c15d6970
3232
refs/heads/beta: 62e70d35be3fe532c26a400b499c58a18f18dd3a
3333
refs/heads/windistfix: 7608dbad651f02e837ed05eef3d74a6662a6e928
3434
refs/tags/1.0.0-alpha: e42bd6d93a1d3433c486200587f8f9e12590a4d7
35-
refs/heads/tmp: 48e9ef640480a5371759d011da7acbe2fa182511
35+
refs/heads/tmp: d136714e04fa244fb45a8459cb717dc682208697
3636
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3737
refs/tags/homu-tmp: b77d60adb019bb5de05e884a99f3290ec4694137
3838
refs/heads/gate: 97c84447b65164731087ea82685580cc81424412

branches/tmp/configure

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -565,7 +565,7 @@ opt rpath 0 "build rpaths into rustc itself"
565565
# This is used by the automation to produce single-target nightlies
566566
opt dist-host-only 0 "only install bins for the host architecture"
567567
opt inject-std-version 1 "inject the current compiler version of libstd into programs"
568-
opt llvm-version-check 1 "check if the LLVM version is supported, build anyway"
568+
opt llvm-version-check 1 "don't check if the LLVM version is supported, build anyway"
569569

570570
# Optimization and debugging options. These may be overridden by the release channel, etc.
571571
opt_nosave optimize 1 "build optimized rust code"
@@ -593,7 +593,6 @@ valopt musl-root "/usr/local" "MUSL root installation directory"
593593
opt_nosave manage-submodules 1 "let the build manage the git submodules"
594594
opt_nosave clang 0 "prefer clang to gcc for building the runtime"
595595
opt_nosave jemalloc 1 "build liballoc with jemalloc"
596-
opt elf-tls 1 "elf thread local storage on platforms where supported"
597596

598597
valopt_nosave prefix "/usr/local" "set installation prefix"
599598
valopt_nosave local-rust-root "/usr/local" "set prefix for local rust binary"

branches/tmp/mk/cfg/x86_64-pc-windows-msvc.mk

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,3 @@ CUSTOM_DEPS_rustc_llvm_T_x86_64-pc-windows-msvc += \
8080
x86_64-pc-windows-msvc/rt/rustc_llvm.def: $(S)src/etc/mklldef.py \
8181
$(S)src/librustc_llvm/lib.rs
8282
$(CFG_PYTHON) $^ $@ rustc_llvm-$(CFG_FILENAME_EXTRA)
83-
84-
# All windows nightiles are currently a GNU triple, so this MSVC triple is not
85-
# bootstrapping from itself. This is relevant during stage0, and other parts of
86-
# the build system take this into account.
87-
BOOTSTRAP_FROM_x86_64-pc-windows-msvc := x86_64-pc-windows-gnu

branches/tmp/mk/crates.mk

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,3 @@ TOOL_INPUTS_$(1) := $$(call rwildcard,$$(dir $$(TOOL_SOURCE_$(1))),*.rs)
150150
endef
151151

152152
$(foreach crate,$(TOOLS),$(eval $(call RUST_TOOL,$(crate))))
153-
154-
ifdef CFG_DISABLE_ELF_TLS
155-
RUSTFLAGS_std := --cfg no_elf_tls
156-
endif

branches/tmp/mk/debuggers.mk

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,8 @@
1515

1616
## GDB ##
1717
DEBUGGER_RUSTLIB_ETC_SCRIPTS_GDB=gdb_load_rust_pretty_printers.py \
18-
gdb_rust_pretty_printing.py
18+
gdb_rust_pretty_printing.py \
19+
debugger_pretty_printers_common.py
1920
DEBUGGER_RUSTLIB_ETC_SCRIPTS_GDB_ABS=\
2021
$(foreach script,$(DEBUGGER_RUSTLIB_ETC_SCRIPTS_GDB), \
2122
$(CFG_SRC_DIR)src/etc/$(script))
@@ -27,7 +28,8 @@ DEBUGGER_BIN_SCRIPTS_GDB_ABS=\
2728

2829

2930
## LLDB ##
30-
DEBUGGER_RUSTLIB_ETC_SCRIPTS_LLDB=lldb_rust_formatters.py
31+
DEBUGGER_RUSTLIB_ETC_SCRIPTS_LLDB=lldb_rust_formatters.py \
32+
debugger_pretty_printers_common.py
3133
DEBUGGER_RUSTLIB_ETC_SCRIPTS_LLDB_ABS=\
3234
$(foreach script,$(DEBUGGER_RUSTLIB_ETC_SCRIPTS_LLDB), \
3335
$(CFG_SRC_DIR)src/etc/$(script))

branches/tmp/mk/main.mk

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -74,6 +74,9 @@ ifneq ($(wildcard $(subst $(SPACE),\$(SPACE),$(CFG_GIT_DIR))),)
7474
endif
7575
endif
7676

77+
CFG_BUILD_DATE = $(shell date +%F)
78+
CFG_VERSION += (built $(CFG_BUILD_DATE))
79+
7780
# Windows exe's need numeric versions - don't use anything but
7881
# numbers and dots here
7982
CFG_VERSION_WIN = $(CFG_RELEASE_NUM)
@@ -127,7 +130,9 @@ CFG_JEMALLOC_FLAGS += $(JEMALLOC_FLAGS)
127130

128131
ifdef CFG_ENABLE_DEBUG_ASSERTIONS
129132
$(info cfg: enabling debug assertions (CFG_ENABLE_DEBUG_ASSERTIONS))
130-
CFG_RUSTC_FLAGS += -C debug-assertions=on
133+
CFG_RUSTC_FLAGS += --cfg debug -C debug-assertions=on
134+
else
135+
CFG_RUSTC_FLAGS += --cfg ndebug
131136
endif
132137

133138
ifdef CFG_ENABLE_DEBUGINFO
@@ -329,6 +334,7 @@ endif
329334
ifdef CFG_VER_HASH
330335
export CFG_VER_HASH
331336
endif
337+
export CFG_BUILD_DATE
332338
export CFG_VERSION
333339
export CFG_VERSION_WIN
334340
export CFG_RELEASE

branches/tmp/mk/target.mk

Lines changed: 0 additions & 39 deletions
Original file line numberDiff line numberDiff line change
@@ -181,42 +181,3 @@ $(foreach host,$(CFG_HOST), \
181181
$(foreach stage,$(STAGES), \
182182
$(foreach tool,$(TOOLS), \
183183
$(eval $(call TARGET_TOOL,$(stage),$(target),$(host),$(tool)))))))
184-
185-
# We have some triples which are bootstrapped from other triples, and this means
186-
# that we need to fixup some of the native tools that a triple depends on.
187-
#
188-
# For example, MSVC requires the llvm-ar.exe executable to manage archives, but
189-
# it bootstraps from the GNU Windows triple. This means that the compiler will
190-
# add this directory to PATH when executing new processes:
191-
#
192-
# $SYSROOT/rustlib/x86_64-pc-windows-gnu/bin
193-
#
194-
# Unfortunately, however, the GNU triple is not known about in stage0, so the
195-
# tools are actually located in:
196-
#
197-
# $SYSROOT/rustlib/x86_64-pc-windows-msvc/bin
198-
#
199-
# To remedy this problem, the rules below copy all native tool dependencies into
200-
# the bootstrap triple's location in stage 0 so the bootstrap compiler can find
201-
# the right sets of tools. Later stages (1+) will have the right host triple for
202-
# the compiler, so there's no need to worry there.
203-
#
204-
# $(1) - stage
205-
# $(2) - triple that's being used as host/target
206-
# $(3) - triple snapshot is built for
207-
# $(4) - crate
208-
# $(5) - tool
209-
define MOVE_TOOLS_TO_SNAPSHOT_HOST_DIR
210-
ifneq (,$(3))
211-
$$(TLIB$(1)_T_$(2)_H_$(2))/stamp.$(4): $$(HLIB$(1)_H_$(2))/rustlib/$(3)/bin/$(5)
212-
213-
$$(HLIB$(1)_H_$(2))/rustlib/$(3)/bin/$(5): $$(TBIN$(1)_T_$(2)_H_$(2))/$(5)
214-
mkdir -p $$(@D)
215-
cp $$< $$@
216-
endif
217-
endef
218-
219-
$(foreach target,$(CFG_TARGET), \
220-
$(foreach crate,$(CRATES), \
221-
$(foreach tool,$(NATIVE_TOOL_DEPS_$(crate)_T_$(target)), \
222-
$(eval $(call MOVE_TOOLS_TO_SNAPSHOT_HOST_DIR,0,$(target),$(BOOTSTRAP_FROM_$(target)),$(crate),$(tool))))))

branches/tmp/mk/tests.mk

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -172,24 +172,23 @@ check: check-sanitycheck cleantmptestlogs cleantestlibs all check-stage2 tidy
172172
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
173173

174174
# As above but don't bother running tidy.
175-
check-notidy: check-sanitycheck cleantmptestlogs cleantestlibs all check-stage2
175+
check-notidy: cleantmptestlogs cleantestlibs all check-stage2
176176
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
177177

178178
# A slightly smaller set of tests for smoke testing.
179-
check-lite: check-sanitycheck cleantestlibs cleantmptestlogs \
179+
check-lite: cleantestlibs cleantmptestlogs \
180180
$(foreach crate,$(TEST_TARGET_CRATES),check-stage2-$(crate)) \
181181
check-stage2-rpass check-stage2-rpass-valgrind \
182182
check-stage2-rfail check-stage2-cfail check-stage2-pfail check-stage2-rmake
183183
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
184184

185185
# Only check the 'reference' tests: rpass/cfail/rfail/rmake.
186-
check-ref: check-sanitycheck cleantestlibs cleantmptestlogs check-stage2-rpass \
187-
check-stage2-rpass-valgrind check-stage2-rfail check-stage2-cfail check-stage2-pfail \
188-
check-stage2-rmake
186+
check-ref: cleantestlibs cleantmptestlogs check-stage2-rpass check-stage2-rpass-valgrind \
187+
check-stage2-rfail check-stage2-cfail check-stage2-pfail check-stage2-rmake
189188
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
190189

191190
# Only check the docs.
192-
check-docs: check-sanitycheck cleantestlibs cleantmptestlogs check-stage2-docs
191+
check-docs: cleantestlibs cleantmptestlogs check-stage2-docs
193192
$(Q)$(CFG_PYTHON) $(S)src/etc/check-summary.py tmp/*.log
194193

195194
# Some less critical tests that are not prone to breakage.

branches/tmp/src/doc/index.md

Lines changed: 0 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -86,14 +86,3 @@ something if you know its name.
8686

8787
If you encounter an error while compiling your code you may be able to look it
8888
up in the [Rust Compiler Error Index](error-index.html).
89-
90-
# Community Translations
91-
92-
Several projects have been started to translate the documentation into other
93-
languages:
94-
95-
- [Russian](https://github.com/kgv/rust_book_ru)
96-
- [Korean](https://github.com/rust-kr/doc.rust-kr.org)
97-
- [Chinese](https://github.com/KaiserY/rust-book-chinese)
98-
- [Spanish](https://github.com/goyox86/elpr)
99-

branches/tmp/src/doc/trpl/guessing-game.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ Finally, Cargo generated a ‘Hello, world!’ for us. Check out `src/main.rs`:
3838

3939
```rust
4040
fn main() {
41-
println!("Hello, world!");
41+
println!("Hello, world!")
4242
}
4343
```
4444

@@ -362,7 +362,7 @@ everything that follows it is part of it, until the next section starts.
362362
Cargo uses the dependencies section to know what dependencies on external
363363
crates you have, and what versions you require. In this case, we’ve used version `0.3.0`.
364364
Cargo understands [Semantic Versioning][semver], which is a standard for writing version
365-
numbers. If we wanted to use the latest version we could use `*` or we could use a range
365+
numbers. If we wanted to use the latest version we could use `*` or we could use a range
366366
of versions. [Cargo’s documentation][cargodoc] contains more details.
367367

368368
[semver]: http://semver.org

branches/tmp/src/doc/trpl/installing-rust.md

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,8 @@
22

33
The first step to using Rust is to install it! There are a number of ways to
44
install Rust, but the easiest is to use the `rustup` script. If you're on Linux
5-
or a Mac, all you need to do is this:
6-
7-
> Note: you don't need to type in the `$`s, they just indicate the start of
8-
> each command. You’ll see many tutorials and examples around the web that
9-
> follow this convention: `$` for commands run as your regular user, and
10-
> `#` for commands you should be running as an administrator.
5+
or a Mac, all you need to do is this (note that you don't need to type in the
6+
`$`s, they just indicate the start of each command):
117

128
```bash
139
$ curl -sf -L https://static.rust-lang.org/rustup.sh | sh

branches/tmp/src/doc/trpl/iterators.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -213,7 +213,7 @@ As we've said before, an iterator is something that we can call the
213213
`.next()` method on repeatedly, and it gives us a sequence of things.
214214
Because you need to call the method, this means that iterators
215215
can be *lazy* and not generate all of the values upfront. This code,
216-
for example, does not actually generate the numbers `1-99`, instead
216+
for example, does not actually generate the numbers `1-100`, instead
217217
creating a value that merely represents the sequence:
218218

219219
```rust
@@ -321,7 +321,7 @@ You can chain all three things together: start with an iterator, adapt it
321321
a few times, and then consume the result. Check it out:
322322

323323
```rust
324-
(1..)
324+
(1..1000)
325325
.filter(|&x| x % 2 == 0)
326326
.filter(|&x| x % 3 == 0)
327327
.take(5)

branches/tmp/src/doc/trpl/mutability.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -89,7 +89,7 @@ philosophy, memory safety, and the mechanism by which Rust guarantees it, the
8989
> * exactly one mutable reference (`&mut T`)
9090
9191
[ownership]: ownership.html
92-
[borrowing]: references-and-borrowing.html#borrowing
92+
[borrowing]: borrowing.html#The-Rules
9393

9494
So, that’s the real definition of ‘immutability’: is this safe to have two
9595
pointers to? In `Arc<T>`’s case, yes: the mutation is entirely contained inside

branches/tmp/src/doc/trpl/raw-pointers.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ For more operations on raw pointers, see [their API documentation][rawapi].
7777
# FFI
7878

7979
Raw pointers are useful for FFI: Rust’s `*const T` and `*mut T` are similar to
80-
C’s `const T*` and `T*`, respectively. For more about this use, consult the
80+
C’s `const T*` and `T*`, respectfully. For more about this use, consult the
8181
[FFI chapter][ffi].
8282

8383
[ffi]: ffi.html

branches/tmp/src/etc/check-sanitycheck.py

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -11,18 +11,19 @@
1111
# except according to those terms.
1212

1313
import os
14-
import subprocess
1514
import sys
1615
import functools
1716

1817
STATUS = 0
1918

19+
2020
def error_unless_permitted(env_var, message):
2121
global STATUS
2222
if not os.getenv(env_var):
2323
sys.stderr.write(message)
2424
STATUS = 1
2525

26+
2627
def only_on(platforms):
2728
def decorator(func):
2829
@functools.wraps(func)
@@ -32,7 +33,8 @@ def inner():
3233
return inner
3334
return decorator
3435

35-
@only_on(['linux', 'darwin', 'freebsd', 'openbsd'])
36+
37+
@only_on(('linux', 'darwin', 'freebsd', 'openbsd'))
3638
def check_rlimit_core():
3739
import resource
3840
soft, hard = resource.getrlimit(resource.RLIMIT_CORE)
@@ -43,14 +45,8 @@ def check_rlimit_core():
4345
set ALLOW_NONZERO_RLIMIT_CORE to ignore this warning
4446
""" % (soft))
4547

46-
@only_on(['win32'])
47-
def check_console_code_page():
48-
if '65001' not in subprocess.check_output(['cmd', '/c', 'chcp']):
49-
sys.stderr.write('Warning: the console output code page is not UTF-8, \
50-
some tests may fail. Use `cmd /c "chcp 65001"` to setup UTF-8 code page.\n')
5148

5249
def main():
53-
check_console_code_page()
5450
check_rlimit_core()
5551

5652
if __name__ == '__main__':

0 commit comments

Comments
 (0)