Commit Graph

75778 Commits

Author SHA1 Message Date
kennytm
50850c62c5
Rollup merge of #49069 - wesleywiser:incr_soa, r=michaelwoerister
Convert SerializedDepGraph to be a struct-of-arrays

Fixes #47326

I did not try the "`mem::swap()` to avoid copying the arrays" idea because that would leave the DepGraph in an incorrect state and that doesn't seem like a good idea for me.

r? @michaelwoerister
2018-03-22 22:43:33 +08:00
kennytm
ca54ff22f2
Rollup merge of #49029 - GuillaumeGomez:atomic-docs, r=QuietMisdreavus
Make Atomic doc examples specific to each type

Fixes #49018.

r? @QuietMisdreavus
2018-03-22 22:43:31 +08:00
kennytm
b7ee149c47
Rollup merge of #48939 - wesleywiser:incr_query_wf_checking, r=michaelwoerister
Querify WF-checking so it can be cached

r? @michaelwoerister
2018-03-22 22:43:30 +08:00
kennytm
d67084215d
Rollup merge of #48759 - QuietMisdreavus:simd-feature-docs, r=GuillaumeGomez
rustdoc: expose #[target_feature] attributes as doc(cfg) flags

This change exposes `#[target_feature(enable = "feat")]` attributes on an item as if they were also `#[doc(cfg(target_feature = "feat"))]` attributes. This gives them a banner on their documentation listing which feature is required to use the item. It also modifies the rendering code for doc(cfg) tags to handle `target_feature` tags. I made it print just the feature name on "short" printings (as in the function listing on a module page), and use "target feature `feat`" in the full banner on the item page itself.

This way, the function listing in `std::arch` shows which feature is required for each function:

![image](https://user-images.githubusercontent.com/5217170/37003222-f41b9d66-2091-11e8-9656-8719e5b34832.png)

![image](https://user-images.githubusercontent.com/5217170/37003234-feb1a7a2-2091-11e8-94de-6d1d76a2d3ee.png)
2018-03-22 17:51:16 +08:00
kennytm
a848336a31
Rollup merge of #48596 - GuillaumeGomez:invalid-code-block-start, r=QuietMisdreavus
Add warning for invalid start of code blocks in rustdoc

Follow up of #48382.

Still two things to consider:
 1. Adding test for rustdoc output (but where? In UI or in rustdoc tests?).
 2. Try to fix the span issue.

r? @QuietMisdreavus
2018-03-22 17:51:15 +08:00
kennytm
d313700014
Rollup merge of #48374 - Aaronepower:master, r=Mark-Simulacrum
Update RELEASES.md for 1.25.0

[rendered](https://github.com/Aaronepower/rust/blob/master/RELEASES.md)
2018-03-22 17:51:13 +08:00
bors
e575773141 Auto merge of #49041 - nikomatsakis:issue-46541-impl-trait-hidden-lifetimes, r=cramertj
Detect illegal hidden lifetimes in `impl Trait`

This branch fixes #46541 -- however, it presently doesn't build because it also *breaks* a number of existing usages of impl Trait. I'm opening it as a WIP for now, just because we want to move on impl Trait, but I'll try to fix the problem in a bit.

~~(The problem is due to the fact that we apparently infer stricter lifetimes in closures that we need to; for example, if you capture a variable of type `&'a &'b u32`, we will put *precisely* those lifetimes into the closure, even if the closure would be happy with `&'a &'a u32`. This causes the present chance to affect things that are not invariant.)~~ fixed

r? @cramertj
2018-03-22 06:56:16 +00:00
bors
eb8d08d904 Auto merge of #49246 - kennytm:download-gcc-stuff-from-https, r=alexcrichton
Download the GCC artifacts from the HTTP server instead of FTP server.

Try to bring back the `dist-i686-linux` and `dist-x86_64-linux alt` builders which has mysteriously lost their cache 14 hours ago and stuck forever unable to download `mpfr-2.4.2.tar.bz2` since it keeps getting

```
==> PASV ... couldn't connect to 209.132.180.131 port 10058: Connection timed out
```
2018-03-22 01:54:51 +00:00
kennytm
9f792e199b
Temporarily disable dist-ing RLS, Rustfmt and Clippy.
Unfortunately we don't have sufficient time to rebuild the cache *and*
distribute everything in `dist-x86_64-linux alt`, the debug assertions are
really slow.

We will re-enable them after the PR has been successfully merged, thus
successfully updating the cache (freeing up 40 minutes), giving us enough
time to build these tools.
2018-03-22 09:45:48 +08:00
QuietMisdreavus
b3fb0d10f0 add target_feature items to doc_cfg rustdoc test 2018-03-21 19:57:10 -05:00
Niko Matsakis
2e8a1abc2d also fix the Fixed code 2018-03-21 19:23:29 -04:00
Niko Matsakis
48c4e352d3 WIP do not use in-band lifetimes 2018-03-21 19:22:41 -04:00
kennytm
56a19a9eec
Handle redirects correctly. 2018-03-22 05:28:11 +08:00
kennytm
78bcbb0f96
Download the GCC artifacts from the HTTP server instead of FTP server.
The former seems much more stable, in case the cache becomes invalidated.
2018-03-22 05:28:04 +08:00
Niko Matsakis
3955708576 WIP tweak example to include feature gate 2018-03-21 16:31:20 -04:00
Niko Matsakis
94eebaa325 WIP fix mir-opt-end-region-8 2018-03-21 09:24:32 -04:00
Niko Matsakis
9d5ec9ef1a work around fallout from these changes in rustc 2018-03-21 05:40:59 -04:00
Niko Matsakis
f71de45b23 use subtyping when we create a closure instead of for upvar types
We used to make the upvar types in the closure `==` but that was
stronger than we needed. Subtyping suffices, since we are copying the
upvar value into the closure field. This in turn allows us to infer
smaller lifetimes in captured values in some cases (like the example
here), avoiding errors.
2018-03-21 05:40:59 -04:00
Niko Matsakis
fc3c90cf8a report an error if we see an unexpected lifetime in impl Trait
But leave closure substs alone.
2018-03-21 05:40:59 -04:00
bors
c19264fa83 Auto merge of #49200 - oli-obk:extern_static_metadata, r=michaelwoerister
Encode/decode extern statics in metadata and incremental cache

fixes #49153

cc @abonander

r? @michaelwoerister incremental ICE
2018-03-21 01:06:16 +00:00
bors
10420536ec Auto merge of #49221 - kennytm:rollup, r=kennytm
Rollup of 3 pull requests

- Successful merges: #49182, #49196, #49217
- Failed merges:
2018-03-20 22:19:50 +00:00
kennytm
de9fb3be1f
Rollup merge of #49217 - kennytm:fix-dpl-788, r=alexcrichton
Apply temporary fix of travis-ci/dpl#788.
2018-03-21 06:18:33 +08:00
kennytm
5f7d7c886c
Rollup merge of #49196 - Phlosioneer:49123-sort-where-conditions, r=QuietMisdreavus
Fix ordering of auto-generated trait bounds in rustdoc output

While the order of the where clauses was deterministic, the
ordering of bounds and lifetimes was not. This made the order flip-
flop randomly when new traits and impls were added to libstd.

This PR makes the ordering of bounds and lifetimes deterministic,
and re-enables the test that was causing the issue.

Fixes #49123
2018-03-21 06:18:32 +08:00
kennytm
e667660d38
Rollup merge of #49182 - matklad:update-clap, r=kennytm
Update clap

This should fix a regression in Cargo after swithing to clap, when
an external subcommand was not discovered, if its name was close to
a built in command.

bug report: https://github.com/rust-lang/rust/pull/48986#issuecomment-374094440
fix: https://github.com/kbknapp/clap-rs/pull/1215
2018-03-21 06:18:31 +08:00
kennytm
20e65f11f3
Apply a fix to travis-ci/dpl#788 manually until dpl 1.9.5 is released. 2018-03-21 06:07:24 +08:00
Niko Matsakis
a9cbfaa296 rewrite to use a custom folder 2018-03-20 16:09:42 -04:00
Aleksey Kladov
8d9774713d Update Cargo to fix regression
This should fix regressions in Cargo after swithing to clap:

* If an external subcommand name was close to built-in one, clap
  errored (fixed by updating clap version)

* External subcomands didn't received their name as a first arg
2018-03-20 15:59:28 +03:00
bors
75af15ee6c Auto merge of #49190 - kennytm:rollup, r=kennytm
Rollup of 17 pull requests

- Successful merges: #46518, #48810, #48834, #48902, #49004, #49092, #49096, #49099, #49104, #49125, #49139, #49152, #49157, #49161, #49166, #49176, #49184
- Failed merges:
2018-03-20 10:18:34 +00:00
Oliver Schneider
13bfbe1394
Encode/decode extern statics in metadata and incremental cache 2018-03-20 10:36:45 +01:00
bors
b99172311c Auto merge of #48516 - petrochenkov:stabsl, r=nikomatsakis
Stabilize slice patterns without `..`

And merge `feature(advanced_slice_patterns)` into `feature(slice_patterns)`.

The detailed description can be found in https://github.com/rust-lang/rust/issues/48836.

Slice patterns were unstable for long time since before 1.0 due to many bugs in the implementation, now this stabilization is possible primarily due to work of @arielb1 who [wrote the new MIR-based implementation of slice patterns](https://github.com/rust-lang/rust/pull/32202) and @mikhail-m1 who [fixed one remaining class of codegen issues](https://github.com/rust-lang/rust/pull/47926).

Reference PR https://github.com/rust-lang-nursery/reference/pull/259
cc https://github.com/rust-lang/rust/issues/23121
fixes #48836
2018-03-20 07:42:19 +00:00
Phlosioneer
7daf3f941a Fix tidy trailing whitespace 2018-03-20 01:02:15 -04:00
Phlosioneer
57e3df3f87 Fix ordering of auto-generated trait bounds in rustdoc output
While the order of the where clauses was deterministic, the
ordering of bounds and lifetimes was not. This made the order flip-
flop randomly when new traits and impls were added to libstd.

This PR makes the ordering of bounds and lifetimes deterministic,
and re-enables the test that was causing the issue.

Fixes #49123
2018-03-19 23:42:14 -04:00
kennytm
57b821112e
Rollup merge of #49184 - bdrewery:update-beta-freebsd, r=alexcrichton
Update beta to version with fixed FreeBSD support from #49023.

Fixes #42681

r? @alexcrichton
2018-03-20 11:39:48 +08:00
kennytm
d5244e4cf5
Rollup merge of #49176 - matthiaskrgr:config_example_rm_thinlto, r=alexcrichton
config.toml.example: thinlto bootstrap was removed

 It was removed in ff227c4a2d so remove the option that no longer works (we did not notice because it was commented out by default).
2018-03-20 11:39:46 +08:00
kennytm
c152e98a75
Rollup merge of #49166 - dileepbapat:pr-49133, r=nikomatsakis
#49133 - Reworded the Error message: "`pub` not needed here" message
2018-03-20 11:39:45 +08:00
kennytm
7fc81fa781
Rollup merge of #49161 - rust-lang:SimonSapin-patch-1, r=KodrAus
Docs: fix incorrect copy-paste for new `X?` in formatting strings
2018-03-20 11:39:44 +08:00
kennytm
cfb531748f
Rollup merge of #49157 - estebank:const-into, r=oli-obk
Do not suggest `.into()` in `const`s

Fix #49100.
2018-03-20 11:39:42 +08:00
kennytm
45de057727
Rollup merge of #49152 - GuillaumeGomez:rustdoc-event-handling, r=QuietMisdreavus
Fix events handling in rustdoc

Fixes #49075.
2018-03-20 11:39:40 +08:00
Wesley Wiser
c43b1a09e0 Convert SerializedDepGraph to be a struct-of-arrays
Fixes #47326
2018-03-19 19:45:35 -04:00
Vadim Petrochenkov
7c90189e13 Stabilize slice patterns without ..
Merge `feature(advanced_slice_patterns)` into `feature(slice_patterns)`
2018-03-20 02:27:40 +03:00
kennytm
1f5d31f8db
Rollup merge of #49139 - sfackler:bufreader-buffer, r=SimonSapin
Add BufReader::buffer

This subsumes the need for an explicit is_empty function, and provides
access to the buffered data itself which has been requested from time to
time.

We could call this `buf` to match `fill_buf`, but I think I'd prefer `fill_buffer` anyways in hindsight.
2018-03-20 07:15:25 +08:00
kennytm
baea60b610
Rollup merge of #49125 - NovemberZulu:master, r=alexcrichton
rustbuild: Ship libsynchronization

Hot on the heels of #49044 comes similar issue with libsynchronization. Discovered while building clippy:
```
<skipped>
Compiling serde_derive v1.0.33
error: linking with `gcc` failed: exit code: 1
<skipped>
  = note: ld: cannot find -lsynchronization
```

r? @nikomatsakis
2018-03-20 07:15:24 +08:00
kennytm
73846dca7b
Rollup merge of #49104 - csmoe:semicolon_error, r=petrochenkov
improve error message of inner attribute syntax

Fixes #49040
2018-03-20 07:15:23 +08:00
kennytm
63ab36190d
Rollup merge of #49099 - glandium:master, r=sfackler
Use associated consts for GenericRadix base and prefix

The trait being private, this does not imply an API change.
2018-03-20 07:15:22 +08:00
kennytm
23e2e3a431
Rollup merge of #49096 - alanhdu:master, r=alexcrichton
Update rustfmt to 0.4.1
2018-03-20 07:15:20 +08:00
kennytm
7bc9fe3250
Rollup merge of #49092 - mark-i-m:deptrack_readme, r=nikomatsakis
Replace many of the last references to readmes

In particular, this removes the dep track readme, so it should not be merged before https://github.com/rust-lang-nursery/rustc-guide/pull/92

Fix #47935

cc #48478

r? @nikomatsakis
2018-03-20 07:15:19 +08:00
kennytm
28eced1cb5
Rollup merge of #49004 - wesleywiser:incr_specialization_graph_query, r=michaelwoerister
Cache the specialization_graph query

Fixes #48987

r? @michaelwoerister
2018-03-20 07:15:18 +08:00
kennytm
7aa66515f6
Rollup merge of #48902 - csmoe:refactor_BorrowckErrors_fn_self, r=nikomatsakis
refactor the `BorrowckErrors` trait to take `fn(self)`

Fixes #48783
2018-03-20 07:15:16 +08:00
kennytm
49b584ce60
Rollup merge of #48834 - ysiraichi:suggest-remove-ref, r=estebank
Suggest removing `&`s

This implements the error message discussed in #47744.
We check whether removing each `&` yields a type that satisfies the requested obligation.
Also, it was created a new `NodeId` field in `ObligationCause` in order to iterate through the `&`s. The way it's implemented now, it iterates through the obligation snippet and counts the number of `&`.

r? @estebank
2018-03-20 07:15:15 +08:00
kennytm
5d5f5a08b8
Rollup merge of #48810 - Phlosioneer:32463-impl-integer-for-wrapping, r=dtolnay
Implement Integer methods for Wrapping

Wrapping<T> now implements:

count_ones, count_zeros, leading_zeros,
trailing_zeros, rotate_left, rotate_right, swap_bytes, from_be,
from_le, to_be, to_le, and pow

where T is:

u8, u16, u32, u64, usize, i8, i16, i32, i64, or isize.

Docs were written for all these methods, as well as examples. The
examples mirror the ones on u8, u16, etc... for consistency.

Closes #32463
2018-03-20 07:15:14 +08:00