]> git.lizzy.rs Git - rust.git/log
rust.git
6 years agoCR feedback
Scott McMurray [Sun, 5 Nov 2017 05:52:45 +0000 (22:52 -0700)]
CR feedback

6 years agoFundamental internal iteration with try_fold
Scott McMurray [Mon, 23 Oct 2017 05:47:27 +0000 (22:47 -0700)]
Fundamental internal iteration with try_fold

This is the core method in terms of which the other methods (fold, all, any, find, position, nth, ...) can be implemented, allowing Iterator implementors to get the full goodness of internal iteration by only overriding one method (per direction).

6 years agoAuto merge of #45285 - alexcrichton:update-bootstrap, r=Mark-Simulacrum
bors [Fri, 27 Oct 2017 18:00:32 +0000 (18:00 +0000)]
Auto merge of #45285 - alexcrichton:update-bootstrap, r=Mark-Simulacrum

Bump to 1.23 and update bootstrap

This commit updates the bootstrap compiler, bumps the version to 1.23, updates
Cargo, updates books, and updates crates.io dependencies

6 years agoUpdate license exceptions.
kennytm [Fri, 27 Oct 2017 14:12:51 +0000 (22:12 +0800)]
Update license exceptions.

The `zircon` crates have been renamed as `fuchsia-zircon`.

6 years agoAuto merge of #45570 - nrc:manifest-no-rls, r=alexcrichton
bors [Fri, 27 Oct 2017 15:03:47 +0000 (15:03 +0000)]
Auto merge of #45570 - nrc:manifest-no-rls, r=alexcrichton

Don't fail to build a manifest if a tarball is missing

This is guesswork because I can't test build_manifest nor do I know what is actually causing the error to begin with. My hypothesis is that when we try to find the version from the RLS tarball and the tarball is not there, then we panic. I attempt to fix this by making the version string optional, then not adding the RLS package, rename, and extension component if the version is missing.

In theory, this should fix the broken nightlies.

r? @alexcrichton

6 years agoAuto merge of #45531 - steveklabnik:fix-unstable-book-formatting, r=kennytm
bors [Fri, 27 Oct 2017 11:16:27 +0000 (11:16 +0000)]
Auto merge of #45531 - steveklabnik:fix-unstable-book-formatting, r=kennytm

Fix formatting in unstable book's attr-literals section

6 years agoAuto merge of #45353 - wesleywiser:untracked_queries, r=michaelwoerister
bors [Fri, 27 Oct 2017 08:34:45 +0000 (08:34 +0000)]
Auto merge of #45353 - wesleywiser:untracked_queries, r=michaelwoerister

[incremental] Add support for eval always queries

Part of #45238

6 years agoDon't fail to build a manifest if a tarball is missing
Nick Cameron [Fri, 27 Oct 2017 05:46:16 +0000 (18:46 +1300)]
Don't fail to build a manifest if a tarball is missing

6 years agoAuto merge of #45524 - alexcrichton:improve-park-unpark, r=dtolnay
bors [Fri, 27 Oct 2017 02:19:16 +0000 (02:19 +0000)]
Auto merge of #45524 - alexcrichton:improve-park-unpark, r=dtolnay

std: Optimize thread park/unpark implementation

This is an adaptation of alexcrichton/futures-rs#597 for the standard library.
The goal here is to avoid locking a mutex on the "fast path" for thread
park/unpark where you're waking up a thread that isn't sleeping or otherwise
trying to park a thread that's already been notified. Mutex performance varies
quite a bit across platforms so this should provide a nice consistent speed
boost for the fast path of these functions.

6 years agoAuto merge of #45523 - alexcrichton:improve-libbacktrace, r=sfackler
bors [Thu, 26 Oct 2017 23:48:16 +0000 (23:48 +0000)]
Auto merge of #45523 - alexcrichton:improve-libbacktrace, r=sfackler

std: Disable usage of mmap allocator in libbacktrace

This is sort of a long overdue change from the investigation in #29293
and #37477. The released binaries of rustc don't have debug information and so
don't actively suffer this problem but this can hit local development of rustc
and also larger programs compiled against libstd generating backtraces.

The main purpose of the mmap allocator in libacktrace is to be usable from a
signal handler, but we don't do that, so the normal allocator using malloc/free
should work well for us.

6 years agoSwitch several crate-wide queries to use eval_always
Wesley Wiser [Mon, 23 Oct 2017 23:08:08 +0000 (19:08 -0400)]
Switch several crate-wide queries to use eval_always

Closes #45238

6 years agoHandle eval_always queries in force()
Wesley Wiser [Mon, 23 Oct 2017 22:10:29 +0000 (18:10 -0400)]
Handle eval_always queries in force()

Part of #45238

6 years agoAllow declaring a DepNode as eval_always
Wesley Wiser [Mon, 23 Oct 2017 22:07:21 +0000 (18:07 -0400)]
Allow declaring a DepNode as eval_always

Part of #45238

6 years ago[incremental] Add support for eval always queries
Wesley Wiser [Wed, 18 Oct 2017 02:50:33 +0000 (22:50 -0400)]
[incremental] Add support for eval always queries

Part of #45238

6 years agoBump to 1.23 and update bootstrap
Alex Crichton [Sat, 14 Oct 2017 15:20:03 +0000 (08:20 -0700)]
Bump to 1.23 and update bootstrap

This commit updates the bootstrap compiler, bumps the version to 1.23, updates
Cargo, updates books, and updates crates.io dependencies

6 years agoAuto merge of #45522 - michaelwoerister:fix-stable-hasher-cross, r=arielb1
bors [Thu, 26 Oct 2017 20:58:08 +0000 (20:58 +0000)]
Auto merge of #45522 - michaelwoerister:fix-stable-hasher-cross, r=arielb1

Fix 32- vs 64-bit platform instability in StableHasher.

This might already be enough to fix issue https://github.com/rust-lang/rust/issues/45500.

r? @alexcrichton

6 years agoAuto merge of #45519 - michaelwoerister:dedup-errors, r=arielb1
bors [Thu, 26 Oct 2017 18:16:15 +0000 (18:16 +0000)]
Auto merge of #45519 - michaelwoerister:dedup-errors, r=arielb1

Don't emit the same compiler diagnostic twice.

This PR makes the compiler filter out diagnostic messages that have already been emitted during the same compilation session.

6 years agoAuto merge of #45380 - dotdash:arg_copies, r=arielb1
bors [Thu, 26 Oct 2017 14:14:15 +0000 (14:14 +0000)]
Auto merge of #45380 - dotdash:arg_copies, r=arielb1

Avoid unnecessary copies of arguments that are simple bindings

Initially MIR differentiated between arguments and locals, which
introduced a need to add extra copies assigning the argument to a
local, even for simple bindings. This differentiation no longer exists,
but we're still creating those copies, bloating the MIR and LLVM IR we
emit.

Additionally, the current approach means that we create debug info for
both the incoming argument (marking it as an argument), and then
immediately shadow it a local that goes by the same name. This can be
confusing when using e.g. "info args" in gdb, or when e.g. a debugger
with a GUI displays the function arguments separately from the local
variables, especially when the binding is mutable, because the argument
doesn't change, while the local variable does.

6 years agoAdd comments to clarify function argument ownership
Björn Steinbrink [Wed, 25 Oct 2017 11:04:59 +0000 (13:04 +0200)]
Add comments to clarify function argument ownership

6 years agoAvoid unnecessary copies of arguments that are simple bindings
Björn Steinbrink [Wed, 11 Oct 2017 18:49:36 +0000 (20:49 +0200)]
Avoid unnecessary copies of arguments that are simple bindings

Initially MIR differentiated between arguments and locals, which
introduced a need to add extra copies assigning the argument to a
local, even for simple bindings. This differentiation no longer exists,
but we're still creating those copies, bloating the MIR and LLVM IR we
emit.

Additionally, the current approach means that we create debug info for
both the incoming argument (marking it as an argument), and then
immediately shadow it a local that goes by the same name. This can be
confusing when using e.g. "info args" in gdb, or when e.g. a debugger
with a GUI displays the function arguments separately from the local
variables, especially when the binding is mutable, because the argument
doesn't change, while the local variable does.

6 years agoUpdate some comments about StableHasher.
Michael Woerister [Thu, 26 Oct 2017 09:10:07 +0000 (11:10 +0200)]
Update some comments about StableHasher.

6 years agoAuto merge of #45488 - oli-obk:ctfe_resolve, r=eddyb
bors [Thu, 26 Oct 2017 07:04:33 +0000 (07:04 +0000)]
Auto merge of #45488 - oli-obk:ctfe_resolve, r=eddyb

Resolve types properly in const eval

r? @eddyb

cc @arielb1

6 years agoAuto merge of #45464 - sinkuu:ice_44851, r=jseyfried
bors [Thu, 26 Oct 2017 04:32:16 +0000 (04:32 +0000)]
Auto merge of #45464 - sinkuu:ice_44851, r=jseyfried

Visit attribute tokens in `DefCollector` and `BuildReducedGraphVisitor`

Fixes #44851.

6 years agoAuto merge of #45096 - DSpeckhals:update-rls-data-for-save-analysis, r=alexcrichton
bors [Thu, 26 Oct 2017 00:58:52 +0000 (00:58 +0000)]
Auto merge of #45096 - DSpeckhals:update-rls-data-for-save-analysis, r=alexcrichton

Update rls-data for save analysis

rls-data: 0.10 -> 0.11

This will allow for more fine-grained save analysis for enum variants (tuple and struct).

The first commit updates rls-data, and makes the changes to dump_visitor. The second commit updates the rls submodule, and removes "members" that were deleted from that update in src/Cargo.toml.

Note, that when building the project, rustfmt-nightly was updated in Cargo.lock. If these changes should be excluded, I can revert it.

cc/ @nrc

6 years agoAdd FIXME
sinkuu [Thu, 26 Oct 2017 00:28:25 +0000 (09:28 +0900)]
Add FIXME

6 years agoAuto merge of #45532 - kennytm:rollup, r=kennytm
bors [Wed, 25 Oct 2017 22:21:44 +0000 (22:21 +0000)]
Auto merge of #45532 - kennytm:rollup, r=kennytm

Rollup of 7 pull requests

- Successful merges: #45059, #45212, #45398, #45483, #45496, #45508, #45526
- Failed merges:

6 years agoRollup merge of #45526 - alexcrichton:test-more-asm, r=aturon
kennytm [Wed, 25 Oct 2017 19:02:54 +0000 (03:02 +0800)]
Rollup merge of #45526 - alexcrichton:test-more-asm, r=aturon

ci: Test more asmjs again

This was accidentally added in #45352, forgot to back it out!

6 years agoRollup merge of #45508 - bgermann:master, r=alexcrichton
kennytm [Wed, 25 Oct 2017 19:02:53 +0000 (03:02 +0800)]
Rollup merge of #45508 - bgermann:master, r=alexcrichton

Disable jemalloc for sparcv9-sun-solaris

Similar to #36994, rust programs segfault on SPARC64 Solaris machines.

6 years agoRollup merge of #45496 - kennytm:bootstrap-fix-extension-check, r=alexcrichton
kennytm [Wed, 25 Oct 2017 19:02:52 +0000 (03:02 +0800)]
Rollup merge of #45496 - kennytm:bootstrap-fix-extension-check, r=alexcrichton

rustbuild: Fix `no output generated` error for next bootstrap cargo.

Due to rust-lang/cargo#4570, a `*.dll.lib` file is uplifted when building dynamic libraries on Windows. The current bootstrap code does not understand files with multiple extensions, and will instead assume `xxxx.dll` is the file name. This caused a `no output generated` error because it tries to search for `xxxx.dll-hash.lib` inside the `deps/` folder, while it should check for `xxxx-hash.dll.lib` instead.

This PR is blocking #45285, see https://github.com/rust-lang/rust/pull/45285#issuecomment-338454149 and the rest of the comments for detail.

6 years agoRollup merge of #45483 - mbrubeck:hash, r=alexcrichton
kennytm [Wed, 25 Oct 2017 19:02:51 +0000 (03:02 +0800)]
Rollup merge of #45483 - mbrubeck:hash, r=alexcrichton

Implement Hash for raw pointers to unsized types

This is useful for some niche cases, like a hash table of slices or trait objects where the key is the raw pointer.  Example use case: https://docs.rs/by_address

6 years agoRollup merge of #45398 - integer32llc:reassignment, r=arielb1
kennytm [Wed, 25 Oct 2017 19:02:50 +0000 (03:02 +0800)]
Rollup merge of #45398 - integer32llc:reassignment, r=arielb1

Correct misspelling in error text: re-assignment => reassignment

[reassignment is the correct spelling](https://www.thefreedictionary.com/reassignment) rather than re-assignment; this error message looks silly in the book next to text trying to be grammatically correct :-/

Will this cause any stability/backcompat type issues?

6 years agoRollup merge of #45212 - GuillaumeGomez:sidebar-fixed, r=QuietMisdreavus
kennytm [Wed, 25 Oct 2017 19:02:49 +0000 (03:02 +0800)]
Rollup merge of #45212 - GuillaumeGomez:sidebar-fixed, r=QuietMisdreavus

Limit the sidebar height

The sidebar is now fixed, which means its scrolling is independent of the main page now.

r? @rust-lang/docs

6 years agoRollup merge of #45059 - tmccombs:pid, r=alexcrichton
kennytm [Wed, 25 Oct 2017 19:02:48 +0000 (03:02 +0800)]
Rollup merge of #45059 - tmccombs:pid, r=alexcrichton

Add current_pid function

Fixes #44971

6 years agoFix formatting in unstable book's attr-literals section
steveklabnik [Wed, 25 Oct 2017 18:23:13 +0000 (14:23 -0400)]
Fix formatting in unstable book's attr-literals section

6 years agoAuto merge of #44636 - GuillaumeGomez:little-error-msg, r=michaelwoerister
bors [Wed, 25 Oct 2017 18:19:42 +0000 (18:19 +0000)]
Auto merge of #44636 - GuillaumeGomez:little-error-msg, r=michaelwoerister

Add short error message-format

Fixes #42653.

6 years agoImplement Hash for raw pointers to unsized types
Matt Brubeck [Mon, 23 Oct 2017 21:21:00 +0000 (14:21 -0700)]
Implement Hash for raw pointers to unsized types

6 years agoci: Test more asmjs again
Alex Crichton [Wed, 25 Oct 2017 16:58:48 +0000 (09:58 -0700)]
ci: Test more asmjs again

This was accidentally added in #45352, forgot to back it out!

6 years agostd: Optimize thread park/unpark implementation
Alex Crichton [Wed, 25 Oct 2017 15:35:51 +0000 (08:35 -0700)]
std: Optimize thread park/unpark implementation

This is an adaptation of alexcrichton/futures-rs#597 for the standard library.
The goal here is to avoid locking a mutex on the "fast path" for thread
park/unpark where you're waking up a thread that isn't sleeping or otherwise
trying to park a thread that's already been notified. Mutex performance varies
quite a bit across platforms so this should provide a nice consistent speed
boost for the fast path of these functions.

6 years agoAuto merge of #45513 - GuillaumeGomez:rollup, r=GuillaumeGomez
bors [Wed, 25 Oct 2017 15:34:03 +0000 (15:34 +0000)]
Auto merge of #45513 - GuillaumeGomez:rollup, r=GuillaumeGomez

Rollup of 5 pull requests

- Successful merges: #45361, #45461, #45465, #45486, #45502
- Failed merges:

6 years agoReword to avoid using either re-assignment or reassignment in errors
Carol (Nichols || Goulding) [Wed, 25 Oct 2017 15:29:14 +0000 (11:29 -0400)]
Reword to avoid using either re-assignment or reassignment in errors

6 years agostd: Disable usage of mmap allocator in libbacktrace
Alex Crichton [Wed, 25 Oct 2017 14:51:36 +0000 (07:51 -0700)]
std: Disable usage of mmap allocator in libbacktrace

This is sort of a long overdue change from the investigation in #29293
and #37477. The released binaries of rustc don't have debug information and so
don't actively suffer this problem but this can hit local development of rustc
and also larger programs compiled against libstd generating backtraces.

The main purpose of the mmap allocator in libacktrace is to be usable from a
signal handler, but we don't do that, so the normal allocator using malloc/free
should work well for us.

6 years agoFix 32 vs 64 bit platform instability in StableHasher.
Michael Woerister [Wed, 25 Oct 2017 14:49:55 +0000 (16:49 +0200)]
Fix 32 vs 64 bit platform instability in StableHasher.

6 years agoUpdate ui tests for error message deduplication.
Michael Woerister [Wed, 25 Oct 2017 13:02:41 +0000 (15:02 +0200)]
Update ui tests for error message deduplication.

6 years agoUpdate compile-fail tests for error message deduplication.
Michael Woerister [Wed, 25 Oct 2017 13:02:26 +0000 (15:02 +0200)]
Update compile-fail tests for error message deduplication.

6 years agolibrustc_errors: Don't emit the same error message twice.
Michael Woerister [Wed, 25 Oct 2017 13:01:06 +0000 (15:01 +0200)]
librustc_errors: Don't emit the same error message twice.

6 years agoAuto merge of #45476 - Xanewok:fingerprint-disambiguator, r=michaelwoerister
bors [Wed, 25 Oct 2017 12:38:10 +0000 (12:38 +0000)]
Auto merge of #45476 - Xanewok:fingerprint-disambiguator, r=michaelwoerister

Use 128 bit instead of Symbol for crate disambiguator

As discussed on gitter, this changes `crate_disambiguator` from Strings to what they are represented as, a 128 bit number.

There's also one bit I think also needs to change, but wasn't 100% sure how: [create_root_def](https://github.com/rust-lang/rust/blob/f338dba29705e144bad8b2a675284538dd514896/src/librustc/hir/map/definitions.rs#L468-L482). Should I change `DefKey::root_parent_stable_hash` to accept `Fingerprint` as crate_disambiguator to quickly combine the hash of `crate_name` with the new 128 bit hash instead of a string for a disambiguator?

r? @michaelwoerister

EDIT: Are those 3 tests `mir-opt` failing, because the hash is different, because we calculate it a little bit differently (storing directly instead of hashing the hex-string representation)? Should it be updated like in #45319?

6 years agoRename some run-pass tests so they don't crash when executed from eCryptfs.
Michael Woerister [Wed, 25 Oct 2017 11:15:04 +0000 (13:15 +0200)]
Rename some run-pass tests so they don't crash when executed from eCryptfs.

6 years agoAdd a regression test for the const eval type resolution
Oliver Schneider [Wed, 25 Oct 2017 07:13:41 +0000 (09:13 +0200)]
Add a regression test for the const eval type resolution

6 years agoResolve types properly in const eval
Oliver Schneider [Tue, 24 Oct 2017 13:10:23 +0000 (15:10 +0200)]
Resolve types properly in const eval

6 years agoRollup merge of #45502 - GuillaumeGomez:show-src-on-mobile, r=QuietMisdreavus
Guillaume Gomez [Wed, 25 Oct 2017 07:48:12 +0000 (09:48 +0200)]
Rollup merge of #45502 - GuillaumeGomez:show-src-on-mobile, r=QuietMisdreavus

Show src button and function version on mobile version

Fixes #45498.

<img width="1440" alt="screen shot 2017-10-24 at 22 36 09" src="https://user-images.githubusercontent.com/3050060/31966689-c0070404-b90b-11e7-8810-810fa0491eda.png">

r? @rust-lang/docs

6 years agoRollup merge of #45486 - oli-obk:patch-9, r=kennytm
Guillaume Gomez [Wed, 25 Oct 2017 07:48:11 +0000 (09:48 +0200)]
Rollup merge of #45486 - oli-obk:patch-9, r=kennytm

Update docs for Diagnostic::span_suggestion(s)

6 years agoRollup merge of #45465 - glaubitz:sparc64, r=alexcrichton
Guillaume Gomez [Wed, 25 Oct 2017 07:48:10 +0000 (09:48 +0200)]
Rollup merge of #45465 - glaubitz:sparc64, r=alexcrichton

bootstrap: Add openssl configuration for sparc64-unknown-linux-gnu

Hi!

This adds the target missing mapping for sparc64-unknown-linux-gnu.

See: https://github.com/rust-lang/rust/issues/45456

Thanks

6 years agoRollup merge of #45461 - wesleywiser:intrinsics_docs, r=dtolnay
Guillaume Gomez [Wed, 25 Oct 2017 07:48:09 +0000 (09:48 +0200)]
Rollup merge of #45461 - wesleywiser:intrinsics_docs, r=dtolnay

Two small enhancements to intrinsics docs

6 years agoRollup merge of #45361 - GuillaumeGomez:fs-docs, r=QuietMisdreavus
Guillaume Gomez [Wed, 25 Oct 2017 07:48:08 +0000 (09:48 +0200)]
Rollup merge of #45361 - GuillaumeGomez:fs-docs, r=QuietMisdreavus

Add missing code examples

r? @rust-lang/docs

6 years agoAuto merge of #45473 - SimonSapin:variance-red-green, r=nikomatsakis
bors [Wed, 25 Oct 2017 05:02:32 +0000 (05:02 +0000)]
Auto merge of #45473 - SimonSapin:variance-red-green, r=nikomatsakis

Remove dependency tracking for variance computation

This custom tracking is now replaced by the red/green algorithm.

Fix https://github.com/rust-lang/rust/issues/45471

6 years agoAuto merge of #45455 - kennytm:print-extern-impl-for-e0119, r=nikomatsakis
bors [Wed, 25 Oct 2017 02:24:03 +0000 (02:24 +0000)]
Auto merge of #45455 - kennytm:print-extern-impl-for-e0119, r=nikomatsakis

Improve diagnostic of E0119 with extern crate, try to print the conflicting impl.

Closes #27403.
Closes #23563.

Should improve #23980.

The diagnostic now looks like:

```
error[E0119]: conflicting implementations of trait `std::convert::Into<_>` for type `GenX<_>`:
  --> $DIR/issue-27403.rs:15:1
   |
15 | / impl<S> Into<S> for GenX<S> {
16 | |     fn into(self) -> S {
17 | |         self.inner
18 | |     }
19 | | }
   | |_^
   |
   = note: conflicting implementation in crate `core`:
           - impl<T, U> std::convert::Into<U> for T
             where U: std::convert::From<T>;

error: aborting due to previous error
```

6 years agoUpdate RLS with skip of failing test
Dustin Speckhals [Wed, 25 Oct 2017 01:29:26 +0000 (21:29 -0400)]
Update RLS with skip of failing test

6 years agoMerge branch 'master' into update-rls-data-for-save-analysis
Dustin Speckhals [Tue, 24 Oct 2017 23:37:15 +0000 (19:37 -0400)]
Merge branch 'master' into update-rls-data-for-save-analysis

6 years agoAuto merge of #44603 - SimonSapin:stylo, r=alexcrichton
bors [Tue, 24 Oct 2017 23:30:15 +0000 (23:30 +0000)]
Auto merge of #44603 - SimonSapin:stylo, r=alexcrichton

Add Stylo and WebRender to src/tools/cargotest

This is a subset of Servo that takes relatively less time to compile and does not use unstable Rust features.

6 years agoDisable jemalloc for sparcv9-sun-solaris
bgermann [Tue, 24 Oct 2017 22:52:56 +0000 (00:52 +0200)]
Disable jemalloc for sparcv9-sun-solaris

Similar to #36994, rust programs segfault on SPARC64 Solaris machines.

6 years agoAuto merge of #45446 - leodasvacas:remove-libcollections, r=alexcrichton
bors [Tue, 24 Oct 2017 20:46:17 +0000 (20:46 +0000)]
Auto merge of #45446 - leodasvacas:remove-libcollections, r=alexcrichton

Remove deprecated `collections` crate.

The real `collections` was merged with `alloc`, this facade was introduced [in this PR](https://github.com/rust-lang/rust/pull/42720) to give `#[no_std]` users time to adapt. This was done at least two cycles ago, now we can consider removing it for good.

6 years agoShow src button and function version on mobile version
Guillaume Gomez [Tue, 24 Oct 2017 20:34:59 +0000 (22:34 +0200)]
Show src button and function version on mobile version

6 years agoFix doc build on other architectures than linux
Guillaume Gomez [Wed, 18 Oct 2017 16:39:44 +0000 (18:39 +0200)]
Fix doc build on other architectures than linux

6 years agoAdd WebRender to cargotest
Simon Sapin [Fri, 15 Sep 2017 15:35:04 +0000 (17:35 +0200)]
Add WebRender to cargotest

6 years agoAdd Stylo to cargotest
Simon Sapin [Fri, 15 Sep 2017 15:34:10 +0000 (17:34 +0200)]
Add Stylo to cargotest

6 years agoFix the sidebar height
Guillaume Gomez [Wed, 11 Oct 2017 18:08:17 +0000 (20:08 +0200)]
Fix the sidebar height

6 years agoSet rustfmt broken while waiting for the update of their side
Guillaume Gomez [Tue, 24 Oct 2017 18:44:02 +0000 (20:44 +0200)]
Set rustfmt broken while waiting for the update of their side

6 years agorustbuild: Fix `no output generated` error for next bootstrap cargo.
kennytm [Tue, 24 Oct 2017 16:32:28 +0000 (00:32 +0800)]
rustbuild: Fix `no output generated` error for next bootstrap cargo.

Due to rust-lang/cargo#4570, a `*.dll.lib` file is uplifted when building
dynamic libraries on Windows. The current bootstrap code does not
understand files with multiple extensions, and will instead assume
`xxxx.dll` is the file name. This caused a `no output generated` error
because it tries to search for `xxxx.dll-hash.lib` inside the `deps/`
folder, while it should check for `xxxx-hash.dll.lib` instead.

This PR is blocking #45285 (Bump to 1.23 and update bootstrap).

6 years agoIntroduce CrateDisambiguator newtype and fix tests
Igor Matuszewski [Tue, 24 Oct 2017 15:49:58 +0000 (17:49 +0200)]
Introduce CrateDisambiguator newtype and fix tests

6 years agoAuto merge of #45350 - cjkenn:cjkenn/used-trait-imports, r=nikomatsakis
bors [Tue, 24 Oct 2017 15:18:08 +0000 (15:18 +0000)]
Auto merge of #45350 - cjkenn:cjkenn/used-trait-imports, r=nikomatsakis

Put used trait imports field into a distinct query

Implementation for #45214

r+ @nikomatsakis

6 years agoAuto merge of #45401 - zackmdavis:crate_shorthand_visibility_modifier, r=nikomatsakis
bors [Tue, 24 Oct 2017 12:24:16 +0000 (12:24 +0000)]
Auto merge of #45401 - zackmdavis:crate_shorthand_visibility_modifier, r=nikomatsakis

`crate` shorthand visibility modifier

cc #45388.

r? @nikomatsakis

6 years agoUpdate docs for Diagnostic::span_suggestion(s)
Oliver Schneider [Tue, 24 Oct 2017 11:08:30 +0000 (13:08 +0200)]
Update docs for Diagnostic::span_suggestion(s)

6 years agobootstrap: Add openssl configuration for sparc64-unknown-linux-gnu
John Paul Adrian Glaubitz [Mon, 23 Oct 2017 09:45:02 +0000 (11:45 +0200)]
bootstrap: Add openssl configuration for sparc64-unknown-linux-gnu

6 years agoAuto merge of #44984 - Maaarcocr:master, r=nikomatsakis
bors [Tue, 24 Oct 2017 03:55:22 +0000 (03:55 +0000)]
Auto merge of #44984 - Maaarcocr:master, r=nikomatsakis

Create NormalizeTy query

As part of the effort to solve #44891,  I've created the normalize_ty query.

As outlined in the issue this meant:

- renamed `normalize_associated_type()` to `normalize_associated_type_in()`
- created the `normalize_ty` query
- substituted the use of memoize with the query

This PR is not ready. While running tests, one of the incremental ones failed. [This](https://pastebin.com/vGhH6bv6) is the error I got.

6 years agoAuto merge of #44766 - sunjay:lift_generics, r=nikomatsakis
bors [Tue, 24 Oct 2017 01:20:09 +0000 (01:20 +0000)]
Auto merge of #44766 - sunjay:lift_generics, r=nikomatsakis

Move Generics from MethodSig to TraitItem and ImplItem

As part of `rust-impl-period/WG-compiler-traits`, we want to "lift" `Generics` from `MethodSig` into `TraitItem` and `ImplItem`. This is in preparation for adding associated type generics. (https://github.com/rust-lang/rust/issues/44265#issuecomment-331172238)

Currently this change is only made in the AST. In the future, it may also impact the HIR. (Still discussing)

To understand this PR, it's probably best to start from the changes to `ast.rs` and then work your way to the other files to understand the far reaching effects of this change.

r? @nikomatsakis

6 years agoupdate inherent_impls tests
Niko Matsakis [Mon, 23 Oct 2017 20:18:00 +0000 (16:18 -0400)]
update inherent_impls tests

Now that we are visiting things in a different order during lowering,
adding parameters winds up affecting the HirIds assigned to thinks in
the method body, whereas it didn't before. We could fix this by
reordering the order in which we visit `generics` during lowering, but
this feels very fragile. Seems better to just let typeck tables be
dirty here.

6 years agoRemove dependency tracking for variance computation
Simon Sapin [Mon, 23 Oct 2017 15:47:07 +0000 (17:47 +0200)]
Remove dependency tracking for variance computation

This custom tracking is now replaced by the red/green algorithm.

Fix https://github.com/rust-lang/rust/issues/45471

6 years agoUse 128 bit instead of Symbol for crate disambiguator
Igor Matuszewski [Mon, 23 Oct 2017 16:44:58 +0000 (18:44 +0200)]
Use 128 bit instead of Symbol for crate disambiguator

6 years agoMove cargotest to separate jobs on Travis-CI and AppVeyor
Simon Sapin [Fri, 15 Sep 2017 18:31:48 +0000 (20:31 +0200)]
Move cargotest to separate jobs on Travis-CI and AppVeyor

6 years agoExtend cargotest to specify packages to test (within a Cargo workspace).
Simon Sapin [Fri, 15 Sep 2017 14:13:48 +0000 (16:13 +0200)]
Extend cargotest to specify packages to test (within a Cargo workspace).

6 years agoFix #44851 by visiting tokens in `DefCollector` and `BuildReducedGraphVisitor`
sinkuu [Mon, 23 Oct 2017 08:22:28 +0000 (17:22 +0900)]
Fix #44851 by visiting tokens in `DefCollector` and `BuildReducedGraphVisitor`

6 years ago`crate` shorthand visibility modifier
Zack M. Davis [Thu, 19 Oct 2017 21:43:47 +0000 (14:43 -0700)]
`crate` shorthand visibility modifier

With regrets, this breaks rustfmt and rls.

This is in the matter of #45388.

6 years agoAdd link to stable version of `needs_drop` intrinsic
Wesley Wiser [Mon, 23 Oct 2017 00:15:56 +0000 (20:15 -0400)]
Add link to stable version of `needs_drop` intrinsic

6 years agoDocument the `size_of_val` instrinsic
Wesley Wiser [Sun, 22 Oct 2017 15:53:29 +0000 (11:53 -0400)]
Document the `size_of_val` instrinsic

6 years agoAuto merge of #45451 - durka:patch-45, r=steveklabnik
bors [Sun, 22 Oct 2017 23:02:15 +0000 (23:02 +0000)]
Auto merge of #45451 - durka:patch-45, r=steveklabnik

fix stringify docs

Update `stringify!` docs to show actual accepted syntax. Reported [on reddit](https://www.reddit.com/r/rust/comments/76o8rh/hey_rustaceans_got_an_easy_question_ask_here/dopzwys/).

6 years agoAuto merge of #45429 - frewsxcv:frewsxcv-once-docs, r=quietmisdreavus
bors [Sun, 22 Oct 2017 20:26:32 +0000 (20:26 +0000)]
Auto merge of #45429 - frewsxcv:frewsxcv-once-docs, r=quietmisdreavus

Improve docs around `Once::call_once_force` and `OnceState`.

Added some examples, clarify behavior, etc etc.

Fixes https://github.com/rust-lang/rust/issues/43472.

6 years agoPrint the conflicting impl on E0119 with external crate.
kennytm [Sun, 22 Oct 2017 15:14:53 +0000 (23:14 +0800)]
Print the conflicting impl on E0119 with external crate.

6 years agoAuto merge of #45304 - kennytm:travis-color-color-conflict, r=aturon
bors [Sun, 22 Oct 2017 17:52:55 +0000 (17:52 +0000)]
Auto merge of #45304 - kennytm:travis-color-color-conflict, r=aturon

Fix rustbuild --color conflict when building on Travis outside of Docker

When trying to build rust on Travis without using `stamp` or `docker`, both `RUSTC_COLOR=1` and `TRAVIS=true` will separately pass `--color always` to the command line. This causes the build to fail due to "*Option 'color' given more than once*".

In this PR, the `RUSTC_COLOR=1` will not be passed in the CI environment.

6 years agofix stringify docs in std
Alex Burka [Sun, 22 Oct 2017 17:17:23 +0000 (13:17 -0400)]
fix stringify docs in std

6 years agofix stringify docs
Alex Burka [Sun, 22 Oct 2017 17:14:17 +0000 (13:14 -0400)]
fix stringify docs

6 years agoDon't build docs for removed libcollections.
leonardo.yvens [Sun, 22 Oct 2017 16:54:07 +0000 (14:54 -0200)]
Don't build docs for removed libcollections.

6 years agoRemove deprecated `collections` crate.
leonardo.yvens [Sun, 22 Oct 2017 12:07:47 +0000 (10:07 -0200)]
Remove deprecated `collections` crate.

This reverts commit 6484258f1749499d3e51685df867b3d460a7f0be.

6 years agoAuto merge of #45442 - matthewjasper:const-dynamic-capture-error, r=petrochenkov
bors [Sun, 22 Oct 2017 15:17:08 +0000 (15:17 +0000)]
Auto merge of #45442 - matthewjasper:const-dynamic-capture-error, r=petrochenkov

Cleanly error for non-const variable in associated const

Not sure if wrapping the whole `visit::walk_impl_item` call is correct.
Closes #44239

6 years agoImprove docs around `Once::call_once_force` and `OnceState`.
Corey Farwell [Sat, 21 Oct 2017 13:20:25 +0000 (09:20 -0400)]
Improve docs around `Once::call_once_force` and `OnceState`.

6 years agoAuto merge of #45432 - ollie27:rustbuild_error_index_gen, r=Mark-Simulacrum
bors [Sun, 22 Oct 2017 11:30:15 +0000 (11:30 +0000)]
Auto merge of #45432 - ollie27:rustbuild_error_index_gen, r=Mark-Simulacrum

rustbuild: Build stage 1 error index generator at stage 0

At stage 1 rustdoc is built at stage 0 so the error index generator should be as well.

This fixes `x.py --stage 1 doc` as rustdoc doesn't even build at stage 1.

It was broken by #44605.

r? @alexcrichton

6 years agoAuto merge of #45433 - ollie27:rustbuild_nomicon, r=Mark-Simulacrum
bors [Sun, 22 Oct 2017 08:55:06 +0000 (08:55 +0000)]
Auto merge of #45433 - ollie27:rustbuild_nomicon, r=Mark-Simulacrum

rustbuild: Fix path for the nomicon

6 years agoAuto merge of #45423 - durka:update-jobserver, r=Mark-Simulacrum
bors [Sun, 22 Oct 2017 03:13:16 +0000 (03:13 +0000)]
Auto merge of #45423 - durka:update-jobserver, r=Mark-Simulacrum

update jobserver version to work around macos bug

Update `jobserver` crate to fix rust-lang/cargo#4643, a panic which can't happen according to `libc::poll`'s man page but was nevertheless reported on macOS 10.9 and 10.10.

r? @alexcrichton

6 years agoAuto merge of #45400 - alexcrichton:bootstrap-thinlto, r=Mark-Simulacrum
bors [Sun, 22 Oct 2017 00:35:05 +0000 (00:35 +0000)]
Auto merge of #45400 - alexcrichton:bootstrap-thinlto, r=Mark-Simulacrum

rustbuild: Compile rustc with ThinLTO

This commit enables ThinLTO for the compiler as well as multiple codegen units.
This is intended to get the benefits of parallel codegen while also avoiding
any major loss of perf. Finally this commit is also intended as further testing
for #45320 and shaking out bugs.

6 years agorenamed query
Marco Concetto Rudilosso [Sat, 21 Oct 2017 21:25:00 +0000 (22:25 +0100)]
renamed query

6 years agoanon NormalizeTy DepNode
Marco Concetto Rudilosso [Sat, 21 Oct 2017 19:11:27 +0000 (20:11 +0100)]
anon NormalizeTy DepNode