Commit graph

70389 commits

Author SHA1 Message Date
kennytm
ae24366251 Rollup merge of #46386 - Aaron1011:fix_rustdoc_log, r=Mark-Simulacrum
Remove librustdoc dependency on env_logger

We want librustdoc to pickup the env_logger dependency from
the sysroot. This ensures that the same copy of env_logger is used
for both internal crates (e.g. librustc_driver, libsyntax) and
librustdoc

Closes #46383
2017-12-02 01:38:57 +08:00
kennytm
2341f6c4e5 Rollup merge of #46385 - alexcrichton:fix-cargo-book, r=Mark-Simulacrum
rustbuild: Fix a typo with the Cargo book

The usage of `Path::new` prevented out-of-tree builds (like the bots do) from
working by accident!

Closes #46195
2017-12-02 01:38:56 +08:00
kennytm
613da5c1f4 Rollup merge of #46376 - SimonSapin:cargoup, r=kennytm
Update Cargo to Wed Nov 29 15:19:05 2017 +0000

5bb478a518

Pick up `workspace.default-members` support: https://github.com/rust-lang/cargo/pull/4743
2017-12-02 01:38:55 +08:00
kennytm
9493d4b95c Rollup merge of #46373 - jakllsch:netbsd-kern_proc_pathname, r=kennytm
NetBSD: add sysctl backend for std::env::current_exe

Use the CTL_KERN.KERN_PROC_ARGS.-1.KERN_PROC_PATHNAME sysctl in
preference over the /proc/curproc/exe symlink.

Additionally, perform more validation of aformentioned symlink.
Particularly on pre-8.x NetBSD this symlink will point to '/' when
accurate information is unavailable.
2017-12-02 01:38:54 +08:00
kennytm
263eb4d7ef Rollup merge of #46280 - tamird:remove-old-refs, r=alexcrichton
rustc_llvm: remove stale references

...that were removed in 77c3bfa742.

r? @alexcrichton
2017-12-02 01:38:53 +08:00
kennytm
95f465d535 Rollup merge of #45880 - arielb1:never-coerce, r=nikomatsakis
make coercions to `!` in unreachable code a hard error

This was added to cover up a lazy extra semicolon in #35849, but does
not actually make sense. This is removed as a part of the stabilization
of `never_type`.
2017-12-02 01:38:52 +08:00
bors
e3ed21272d Auto merge of #46236 - davidtwco:issue-46023, r=arielb1
MIR-borrowck: immutable unique closure upvars can be mutated

Fixes #46023 and #46160 (see [this comment](https://github.com/rust-lang/rust/pull/46236#issuecomment-347204874)).
2017-12-01 13:26:10 +00:00
bors
315fbf7518 Auto merge of #46211 - snipsco:master, r=pnkfelix
disable jemalloc on executables for ios targets

This is a (temporary ?) workaround for issue #45262
2017-12-01 08:44:42 +00:00
bors
d1364a65c0 Auto merge of #45997 - estebank:pub-ident, r=nikomatsakis
Account for missing keyword in fn/struct definition

Fix #38911.
2017-12-01 06:06:06 +00:00
bors
804b15be82 Auto merge of #45846 - pietroalbini:use-nested-groups, r=petrochenkov
Add nested groups in imports

This PR adds support for nested groups in imports (rust-lang/rfcs#2128, tracking issue #44494).

r? @petrochenkov
2017-12-01 03:25:54 +00:00
bors
d8a60c9611 Auto merge of #46370 - michaelwoerister:rm-metadata-hashing, r=eddyb
incr.comp.: Remove ability to produce incr. comp. hashes during metadata export.

This functionality has been superseded by on-import hashing, which can be less conservative and does not require extra infrastructure.

r? @nikomatsakis
2017-12-01 00:46:08 +00:00
David Wood
c6b1ba56d7
Fixed spurious cannot borrow immutable item error with a closure. 2017-11-30 23:19:06 +00:00
David Wood
dedbb4edd1
Immutable unique closure upvars cannot be mutated. 2017-11-30 23:18:38 +00:00
David Wood
c3459b0c9c
Added test for spurious cannot borrow immutable item error with a closure 2017-11-30 23:16:17 +00:00
David Wood
347f631325
Added test for immutable unique closure upvar mutation. 2017-11-30 23:15:10 +00:00
Mathieu Poumeyrol
3b18e29d2c explanatory note for the workaround 2017-11-30 23:14:29 +01:00
bors
23032d0afa Auto merge of #46402 - oli-obk:clippy, r=kennytm
Reenable clippy
2017-11-30 19:18:14 +00:00
Jonathan A. Kollasch
ccef9696f1 NetBSD: add sysctl backend for std::env::current_exe
Use the CTL_KERN.KERN_PROC_ARGS.-1.KERN_PROC_PATHNAME sysctl in
preference over the /proc/curproc/exe symlink.

Additionally, perform more validation of aformentioned symlink.
Particularly on pre-8.x NetBSD this symlink will point to '/' when
accurate information is unavailable.
2017-11-30 12:17:44 -06:00
Oliver Schneider
208deac1c9
Reenable clippy 2017-11-30 16:12:24 +01:00
Ariel Ben-Yehuda
5a00b7cb74 make coercions to ! in unreachable code a hard error
This was added to cover up a lazy extra semicolon in #35849, but does
not actually make sense. This is removed as a part of the stabilization
of `never_type`.
2017-11-30 15:18:25 +02:00
Pietro Albini
f7f69512c8
Mark rustfmt and rls as broken 2017-11-30 13:24:59 +01:00
Pietro Albini
91ba8b42fc
Implement RFC 2128 (use_nested_groups)
This commit adds support for nested groups inside `use` declarations,
such as `use foo::{bar, sub::{baz::Foo, *}};`.
2017-11-30 13:10:26 +01:00
bors
4fa202d23b Auto merge of #46299 - michaelwoerister:incr-comp-krimskrams, r=nikomatsakis
incr.comp.: Some preparatory work for caching more query results.

This PR
* adds and updates some encoding/decoding routines for various query result types so they can be cached later, and
* adds missing `[input]` annotations for a few `DepNode` variants.

The situation around having to explicitly mark dep-nodes/queries as inputs is not really satisfactory. I hope we can find a way of making this more fool-proof in the future.

r? @nikomatsakis
2017-11-30 10:57:21 +00:00
Simon Sapin
2544b9fbf0 Update Cargo to Wed Nov 29 15:19:05 2017 +0000
5bb478a518

Pick up `workspace.default-members` support:
https://github.com/rust-lang/cargo/pull/4743
2017-11-30 09:02:23 +01:00
bors
d6b010f98b Auto merge of #46226 - arielb1:special-region-obligation, r=nikomatsakis
avoid type-live-for-region obligations on dummy nodes

Type-live-for-region obligations on DUMMY_NODE_ID cause an ICE, and it
turns out that in the few cases they are needed, these obligations are not
needed anyway because they are verified elsewhere.

Fixes #46069.

Beta-nominating because this is a regression for our new beta.
r? @nikomatsakis
2017-11-30 08:00:27 +00:00
bors
909b94b5cc Auto merge of #46041 - zilbuz:issue-44837, r=arielb1
MIR borrowck: finalize `check_access_permissions()`

Fix #44837 (hopefully for good)

r? @arielb1
2017-11-30 05:26:28 +00:00
bors
78fcf33883 Auto merge of #46366 - kennytm:revert-46360, r=kennytm
Revert #46360, re-enable macOS dist images.

This PR reverts #46360, which disabled all macOS dist images to workaround travis-ci/travis-ci#8821.

This PR should be merged as soon as the Travis bug has been fixed.

Closes #46357.

cc @rust-lang/infra
2017-11-30 01:28:44 +00:00
Aaron Hill
21228a82b0
Remove librustdoc dependency on env_logger
We want librustdoc to pickup the env_logger dependency from
the sysroot. This ensures that the same copy of env_logger is used
for both internal crates (e.g. librustc_driver, libsyntax) and
librustdoc

Closes #46383
2017-11-29 18:10:42 -05:00
Alex Crichton
326eb79cf6 rustbuild: Fix a typo with the Cargo book
The usage of `Path::new` prevented out-of-tree builds (like the bots do) from
working by accident!

Closes #46195
2017-11-29 15:00:52 -08:00
bors
74bc14d0fe Auto merge of #46144 - nrc:rls-update, r=alexcrichton
Update RLS and Rustfmt

r? @alexcrichton
2017-11-29 22:41:05 +00:00
Michael Woerister
7ebccbb7a4 incr.comp.: Update test cases after metadata hashing removal. 2017-11-29 16:29:13 +01:00
Michael Woerister
c60b0e43c8 incr.comp.: Remove on-export crate metadata hashing. 2017-11-29 16:28:25 +01:00
kennytm
6b5f430a6c
Revert "Auto merge of #46360 - kennytm:workaround-travis-8821, r=kennytm"
This reverts commit dc0e227745, reversing
changes made to 77ab3a1d5f.

[skip ci]
2017-11-29 21:03:53 +08:00
bors
0a2e9ade83 Auto merge of #46362 - kennytm:rollup, r=kennytm
Rollup of 10 pull requests

- Successful merges: #45969, #46077, #46219, #46287, #46293, #46322, #46323, #46330, #46354, #46356
- Failed merges:
2017-11-29 12:17:45 +00:00
kennytm
51bd916af4 Rollup merge of #46356 - daboross:patch-2, r=sfackler
Reject '2' as a binary digit in internals of b: number formatting

The `radix!` macro generates an implementation of the private trait `GenericRadix`, and the code replaced changes Binary's implementation to no longer accept '2' as a valid digit to print.

Granted, this code is literally only ever called from another method in this private trait, and that method has logic to never hand a '2' to the printing function. Even given this, the code's there, I thought it would be best to fix this for clarity of anyone reading it.
2017-11-29 18:37:54 +08:00
kennytm
9a93df9b58 Rollup merge of #46354 - Mark-Simulacrum:alt-try, r=alexcrichton
Deploy builds both with asserts enabled and asserts disabled to CI.

This also removes uploads to the 'try' bucket, and instead dumps
everything into the two rustc-builds and rustc-builds-alt buckets. This
makes lives easier, as there is only one location for a given "type" of
build, and since we have the git commit hash in the filenames, this is
fine; we won't run into uploads of the same commit.

cc @aidanhs -- this will break crater's logic for downloading `try#xxx` commits since the try bucket won't be uploaded into

r? @alexcrichton
2017-11-29 18:37:53 +08:00
kennytm
1e49d4a6cd Rollup merge of #46330 - SimonSapin:patch-6, r=kennytm
Update comment on alternate builds in .travis.yml

https://github.com/rust-lang/rust/pull/45810#issuecomment-347257640
2017-11-29 18:37:52 +08:00
kennytm
30f1853649 Rollup merge of #46323 - ia0:fix_mpsc_error_conv, r=kennytm
Fix since for mpsc_error_conversions

This is a followup of #45506.
2017-11-29 18:37:51 +08:00
kennytm
a19c13a698 Rollup merge of #46322 - gnzlbg:mmx, r=alexcrichton
white list MMX and MSA target features

r? @alexcrichton
2017-11-29 18:37:50 +08:00
kennytm
fc9abbd7b7 Rollup merge of #46293 - ollie27:atomic_bool_from, r=BurntSushi
impl From<bool> for AtomicBool

This seems like an obvious omission from #45610. ~~I've used the same feature name and version in the hope that this can be backported to beta so it's stabilized with the other impls. If it can't be I'll change it to `1.24.0`.~~
2017-11-29 18:37:50 +08:00
kennytm
0e78c29bea Rollup merge of #46287 - SimonSapin:stable-constness, r=aturon
Stabilize const-calling existing const-fns in std

Fixes #46038
2017-11-29 18:37:47 +08:00
kennytm
6006c0f35f Rollup merge of #46219 - rust-lang:frewsxcv-issue-45636, r=GuillaumeGomez
Improve documentation for slice swap/copy/clone operations.

Fixes #45636.

- Demonstrate how to use these operations with slices of differing
  lengths
- Demonstrate how to swap/copy/clone sub-slices of a slice using
  `split_at_mut`
2017-11-29 18:37:45 +08:00
kennytm
963ab91dd4 Rollup merge of #46077 - LukasKalbertodt:stabilize-ascii-ctype, r=alexcrichton
Stabilize some `ascii_ctype` methods

As discussed in #39658, this PR stabilizes those methods for `u8` and `char`. All inherent `ascii_ctype` for `[u8]` and `str` are removed as we prefer the more explicit version `s.chars().all(|c| c.is_ascii_())`.

This PR doesn't modify the `AsciiExt` trait. There, the `ascii_ctype` methods are still unstable. It is planned to remove those in the future (I think). I had to modify some code in `ascii.rs` to properly implement `AsciiExt` for all types.

Fixes #39658.
2017-11-29 18:37:44 +08:00
kennytm
0ec3aee569 Rollup merge of #45969 - ia0:mpsc_recv_deadline, r=alexcrichton
Add std::sync::mpsc::Receiver::recv_deadline()

Essentially renames recv_max_until to recv_deadline (mostly copying recv_timeout
documentation). This function is useful to avoid the often unnecessary call to
Instant::now in recv_timeout (e.g. when the user already has a deadline). A
concrete example would be something along those lines:

```rust
use std::sync::mpsc::Receiver;
use std::time::{Duration, Instant};

/// Reads a batch of elements
///
/// Returns as soon as `max_size` elements have been received or `timeout` expires.
fn recv_batch_timeout<T>(receiver: &Receiver<T>, timeout: Duration, max_size: usize) -> Vec<T> {
    recv_batch_deadline(receiver, Instant::now() + timeout, max_size)
}

/// Reads a batch of elements
///
/// Returns as soon as `max_size` elements have been received or `deadline` is reached.
fn recv_batch_deadline<T>(receiver: &Receiver<T>, deadline: Instant, max_size: usize) -> Vec<T> {
    let mut result = Vec::new();
    while let Ok(x) = receiver.recv_deadline(deadline) {
        result.push(x);
        if result.len() == max_size {
            break;
        }
    }
    result
}
```
2017-11-29 18:37:43 +08:00
bors
dc0e227745 Auto merge of #46360 - kennytm:workaround-travis-8821, r=kennytm
Disable all macOS dist images to workaround travis-ci/travis-ci#8821

See: travis-ci/travis-ci#8821

Currently the [Travis status](https://www.traviscistatus.com/) is all green, I don't know how long it takes Travis to notice and fix it, so I'm merging this in immediately to keep the queue running today.

cc @rust-lang/infra
2017-11-29 09:44:04 +00:00
kennytm
666c24136b
Disable all macOS dist images to workaround travis-ci/travis-ci#8821
[skip ci]
2017-11-29 17:39:36 +08:00
Nick Cameron
1cec22e157 Update Rustfmt again 2017-11-29 20:34:06 +13:00
Nick Cameron
02c89f703d Rebased Cargo.lock 2017-11-29 19:17:20 +13:00
Nick Cameron
500b791b30 Update Cargo
Pulls in https://github.com/rust-lang/cargo/pull/4762 fixing a broken test which prevented the RLS update
2017-11-29 19:15:54 +13:00
Nick Cameron
1b50f68135 Update RLS and Rustfmt 2017-11-29 19:15:46 +13:00