Commit Graph

89912 Commits

Author SHA1 Message Date
kennytm
ef0aaddf69
Rollup merge of #58551 - ssomers:master, r=oli-obk
Explain a panic in test case net::tcp::tests::double_bind

Those who try to build libstd on the Windows Subsystem for Linux experience a single failing test, where the point of failure is an explicit but anonymous panic, as reported in https://github.com/rust-lang/rust/issues/49367
This commit somewhat explains why and allows diagnosing a little.
2019-02-20 11:59:07 +08:00
kennytm
8368638515
Rollup merge of #58546 - taiki-e:librustc_codegen_llvm-2018, r=Centril
librustc_codegen_llvm => 2018

Transitions `librustc_codegen_llvm` to Rust 2018; cc #58099

r? @Centril
2019-02-20 11:59:04 +08:00
kennytm
fd18e3f35e
Rollup merge of #58545 - emlai:regression-test-for-39448, r=Centril
Add regression test for a specialization-related ICE (#39448)

Closes #39448.

This is my first time contributing, I hope I got everything right. :)
2019-02-20 11:59:02 +08:00
kennytm
717aa46178
Rollup merge of #58544 - TheBiggerGuy:rustc-doc-cli-args, r=TimNN
Fix doc for rustc "-g" flag

The rustc `-g` CLI flag was miss documented to be a synonym of `-C debug-level=2` and not `-C debuglevel=2`. Also add links to the codegen docs for each synonym.

I am unsure of this will conflict with work on #52938
2019-02-20 11:58:58 +08:00
kennytm
c965858e20
Rollup merge of #58539 - aaronstillwell:master, r=Mark-Simulacrum
Add alias methods to PathBuf for underlying OsString (#58234)

Implemented the following methods on PathBuf which forward to the underlying OsString.

- capacity
- with_capacity
- clear
- reserve
- reserve_exact
- shrink_to_fit
- shrink_to

These methods have been documented with reference to the original docs for `OsString`. @Mark-Simulacrum please let me know if you feel this does not suffice.

Further, I've not yet included tests for these definitions - please advise on how comprehensive tests need to be for methods such as these that simply alias other (already tested) methods.

(This PR addresses issue #58234)
2019-02-20 11:58:55 +08:00
kennytm
a68a1c758d
Rollup merge of #58538 - GuillaumeGomez:fmt-examples, r=Centril
Add missing fmt structs examples

r? @rust-lang/docs
2019-02-20 11:58:52 +08:00
kennytm
943fe1ee2c
Rollup merge of #58536 - xfix:remove-ub-in-pointer-tests, r=RalfJung
Remove UB in pointer tests

UB found by Miri.
2019-02-20 11:58:48 +08:00
kennytm
51445830d2
Rollup merge of #58534 - dwijnand:mention-capping-forbid-lints, r=oli-obk
Mention capping forbid lints

I felt the description of forbid was misleading/incomplete without
mentioning how --cap-lints interacts with it.
2019-02-20 11:58:45 +08:00
kennytm
7ef11d4f84
Rollup merge of #58530 - scottmcm:monomorphize-less, r=TimNN
Monomorphize less code in fs::{read|write}

Since the generic-ness is only for the as_refs, might as well have std just compile the important part once instead of on every use.
2019-02-20 11:58:42 +08:00
kennytm
e95297ca15
Rollup merge of #58528 - Zoxc:stmtkind-item, r=oli-obk
Don't use an allocation for ItemId in StmtKind
2019-02-20 11:58:38 +08:00
kennytm
897778ec28
Rollup merge of #58456 - lzutao:nll, r=Centril
Remove no longer accurate diagnostic code about NLL

r? @steveklabnik
2019-02-20 11:58:35 +08:00
kennytm
8d1e4323b3
Rollup merge of #58409 - euclio:impl-trait-wrapping, r=QuietMisdreavus
rustdoc: respect alternate flag when formatting impl trait

Fixes #58226.

Before:
<img width="963" alt="screen shot 2019-02-12 at 3 23 30 pm" src="https://user-images.githubusercontent.com/1372438/52665732-4496ea00-2eda-11e9-9e29-efffe43b2abf.png">

After:
<img width="964" alt="screen shot 2019-02-12 at 3 23 51 pm" src="https://user-images.githubusercontent.com/1372438/52665733-452f8080-2eda-11e9-999a-dd1fb28dee16.png">
2019-02-20 11:58:31 +08:00
kennytm
98a6e720d0
Rollup merge of #58392 - scottmcm:less-shifting-in-net-ip, r=oli-obk
Use less explicit shifting in std::net::ip

Now that we have `{to|from}_be_bytes` the code can be simpler.

(Inspired by PR #57740)
2019-02-20 11:58:26 +08:00
kennytm
07b6d17416
Rollup merge of #58384 - GuillaumeGomez:fix-table-display, r=QuietMisdreavus
Fix tables display

Fixes #58134.

cc @lzutao

r? @QuietMisdreavus
2019-02-20 11:58:22 +08:00
kennytm
d22bb1a8b4
Rollup merge of #58336 - GuillaumeGomez:fix-search-results-interactions, r=oli-obk
Fix search results interactions

The bug is visible when you search for "none": the second tab is empty and therefore it messes with the classes. Then when you try to use arrows on the third tab, it just crashes (because only 2 "search-results" are present and you're on tab 3).

r? @QuietMisdreavus
2019-02-20 11:58:16 +08:00
kennytm
120e9cb70f
Rollup merge of #58303 - GuillaumeGomez:stability-tags-display, r=QuietMisdreavus
Improve stability tags display

The issue was the font color on dark theme. Fixed now:

<img width="352" alt="screenshot 2019-02-08 at 14 15 24" src="https://user-images.githubusercontent.com/3050060/52483276-bd810380-2bb3-11e9-8d46-95368569ac85.png">

r? @QuietMisdreavus
2019-02-20 11:58:11 +08:00
kennytm
5a06eab1f5
Rollup merge of #56470 - llogiq:process-termination-doctest, r=GuillaumeGomez
Modify doctest's auto-`fn main()` to allow `Result`s

This lets the default `fn main()` ~~return `impl Termination`~~ unwrap Results, which allows the use of `?` in most tests without adding it manually. This fixes #56260

~~Blocked on `std::process::Termination` stabilization.~~

Using `Termination` would have been cleaner, but this should work OK.
2019-02-20 01:13:12 +08:00
Guillaume Gomez
31ee20db3e Add missing fmt structs examples 2019-02-19 11:20:00 +01:00
Guillaume Gomez
b53305df7f Fix tables display 2019-02-19 11:07:16 +01:00
bors
4d66b7b76d Auto merge of #58571 - Manishearth:rustup, r=Manishearth
Update clippy, RLS, and rustfmt

moved from https://github.com/rust-lang/rust/pull/58337
2019-02-19 10:06:55 +00:00
Manish Goregaokar
cd99bd3a3d Update clippy to rust-lang/rust-clippy@d61b25419b 2019-02-19 13:36:31 +05:30
bors
fcccf06fc9 Auto merge of #56514 - ollie27:rustdoc_test_libdir, r=QuietMisdreavus
rustdoc: Don't modify library path for doctests

It shouldn't be needed anymore because doctests are no longer compiled with `prefer-dynamic` (since #54939).

r? @QuietMisdreavus
2019-02-19 07:27:39 +00:00
bors
32471f7ea4 Auto merge of #58503 - varkor:const-generics-hir, r=petrochenkov
Add const generics to the HIR

Split out from https://github.com/rust-lang/rust/pull/53645.

cc @yodaldevoid

r? @eddyb
2019-02-19 00:46:12 +00:00
bors
c61b92beaa Auto merge of #58543 - jonas-schievink:bumpstrap, r=pietroalbini
Bump the bootstrap compiler

This compiler includes https://github.com/rust-lang/rust/pull/58501, which fixes an annoying ICE while working on rustc itself.

r? @pietroalbini
2019-02-18 22:03:41 +00:00
Aaron Stillwell
c9fbcc1f39 Fixed doc example for Path::with_capacity 2019-02-18 17:42:07 +00:00
bors
146aa60f34 Auto merge of #58549 - pietroalbini:fix-docker-ci-hash, r=Mark-Simulacrum
ci: fix docker cache hash collision

#58416 uncovered a bug in our caching for docker images: if the image `foo` pulls files from the image `bar` and a file in `bar` changed, the hash of `foo` will be the same even though it should be different. In that PR's case, `dist-i686-linux` pulls scripts from `dist-x86_64-linux`, and the PR only changed those scripts, causing an hash collision for `dist-i686-linux`.

We have to fix this, since the image will be rebuilt every time bors switches from testing master to testing beta/stable (and when it switches back), making CI way more painful than it currently is.

The approach used by this PR is to just include all the files in `src/ci/docker` in the hash. It's a bit heavy-handed and it will cause a rebuild of all the images every time a single image changes, but it's the best I can think of.

r? @Mark-Simulacrum
cc @alexcrichton @kennytm
2019-02-18 17:34:14 +00:00
Pietro Albini
2b2045d161
ci: fix docker cache hash collision
Before this commit the hash used to cache docker images was calculated
from the image's files and the files in the scripts/ directory. This
worked fine when all the files used by an image were in those
directories, but some images pull files from other images, causing hash
collisions in some cases.

This commit changes the hash to include the files of all the docker
images, causing a rebuild of all the images when a single one changes.
That's a bit heavy-handed, but we have no way to track which files an
image pulls in and hash collisions are really painful to deal with.
2019-02-18 15:28:10 +01:00
flip1995
4c228cc9b8
Update Cargo.lock 2019-02-18 10:32:58 +01:00
flip1995
4f96a03ab3
Add constant_time_eq to license exception list of tidy tool 2019-02-18 10:32:00 +01:00
flip1995
919b3f9da3
Update Cargo.toml of rustc-workspace-hack 2019-02-18 10:31:59 +01:00
flip1995
5f483570a0
Update rustfmt to rust-lang/rustfmt@d6829d 2019-02-18 10:31:59 +01:00
flip1995
ed17700018
Update RLS to rust-lang/rls@0d6f53 2019-02-18 10:31:59 +01:00
flip1995
af38382dec
Update Clippy to rust-lang/rust-clippy@32ee30 2019-02-18 10:31:59 +01:00
bors
684b09ba7f Auto merge of #58541 - kennytm:fix-publish-toolstate-py-again, r=oli-obk
publish_toolstate.py: further fix the runtime errors

The regex was missing a `,`, causing `relevant_pr_match` to become None and set the PR number to -1 and assigned the new issue to `@<unknown user>`. This causes the 422 error when creating the issue due to invalid assignee and unable to leave the tool-is-broken comment since PR -1 does not exist.

The default user names are now also changed to @ghost to prevent the 422 error in case anything goes wrong again.
2019-02-18 08:37:18 +00:00
bors
d215d9591f Auto merge of #58373 - RalfJung:maybe-uninit, r=gnzlbg
update stdsimd and remove now-unused MaybeUninit::into_inner

That's a huge diff for stdsimd... Cc @gnzlbg @alexcrichton
2019-02-18 02:56:18 +00:00
Stein Somers
01bebdf193 Merge remote-tracking branch 'upstream/master' 2019-02-18 00:31:41 +01:00
Stein Somers
0b9ad6e6fd Explain a panic in test case net::tcp::tests::double_bind 2019-02-18 00:13:31 +01:00
Guy Taylor
88e462bf7f Add links to codegen docs for rustc synonym flags
The rustc "-g" and "-o" fags are synonyms of the "-c" codegen flags.
This adds a link to the codegen docs for each synonym.
2019-02-17 19:45:13 +00:00
Guy Taylor
55c25f8c8d Fix doc for rustc "-g" flag
The rustc "-g" CLI flag was miss documented to be a synonym of "-C
debug-level=2" and not the correct "-C debuginfo=2".
2019-02-17 19:44:45 +00:00
Taiki Endo
1b7ca961d9 librustc_codegen_llvm => 2018 2019-02-18 03:58:58 +09:00
emlai
ee948d9981 Add regression test for a specialization-related ICE (#39448) 2019-02-17 20:41:18 +02:00
Jonas Schievink
1a0d800ef6 Bump the bootstrap compiler 2019-02-17 18:14:32 +01:00
Aaron Stillwell
35d8c4400d Changed feature gate for new PathBuf methods
Feature gate changed to `path_buf_capacity` as per advice from @Mark-Simulacrum
2019-02-17 17:14:10 +00:00
Aaron Stillwell
dbf60d9ca1 Fixes for implementation of PathBuf methods (aliases for OsString)
- Fixed incorrect `mut` usage
- Fixed style in accordance with tidy
- Marked all methods as unstable
- Changed feature identifier to path_buf_alias_os_string_methods
2019-02-17 16:41:05 +00:00
Andre Bogus
dad211ef9f Modify doctest's auto-fn main() to allow Results
This lets the default `fn main()` unwrap any `Result`s, which
allows the use of `?` in most tests without adding it manually.
2019-02-17 16:42:49 +01:00
kennytm
66ae3131fc
publish_toolstate.py: further fix the runtime errors
The regex was missing a `,`, causing `relevant_pr_match` to become None
and set the PR number to -1 and assigned the new issue to
`@<unknown user>`. This causes the 422 error when creating the issue due
to invalid assignee and unable to leave the tool-is-broken comment since
PR -1 does not exist.

The default user names are now also changed to @ghost to prevent the
422 error in case anything goes wrong again.
2019-02-17 23:39:50 +08:00
Aaron Stillwell
a23c40ec94 Add alias methods to PathBuf for underlying OsString
Implemented the following methods on PathBuf which
forward to the underlying OsString.

- capacity
- with_capacity
- clear
- reserve
- reserve_exact
- shrink_to_fit
- shrink_to
2019-02-17 15:17:46 +00:00
bors
9a3392e174 Auto merge of #58416 - cuviper:dist-linux-gcc, r=alexcrichton
[CI] Update GCC in the dist-linux builders

Upstream LLVM is planning to raise their minimum toolchain requirements, so they may start using C++14 features. This new policy has already landed in the form of a "soft" error.
http://lists.llvm.org/pipermail/llvm-dev/2019-February/130117.html

For GCC, they will require at least version 5.1. This PR moves our crosstool-ng builders to their max GCC 5.2, with a few small patches to fix compatibility. The dist-x86_64-linux builder is updated to GCC 5.5 and LLVM/Clang 8.0.0-rc2, which also affects dist-i686-linux sharing the same scripts.

r? @alexcrichton
2019-02-17 14:29:33 +00:00
Konrad Borowski
0cf1a912e3 Remove UB in test_ptr_subtraction test 2019-02-17 13:04:48 +01:00
Konrad Borowski
3281e62188 Remove UB in test_is_null test 2019-02-17 12:58:48 +01:00