]> git.lizzy.rs Git - rust.git/log
rust.git
5 years agomodify comment
Felix S Klock II [Mon, 13 May 2019 11:29:49 +0000 (13:29 +0200)]
modify comment

modify the comment on `in_cycle` to reflect changes requested by ariel and myself.

5 years agoforego caching for all participants in cycles, apart from root node
Niko Matsakis [Wed, 1 May 2019 17:10:01 +0000 (13:10 -0400)]
forego caching for all participants in cycles, apart from root node

5 years agoAuto merge of #60195 - varkor:commontypes-to-common, r=eddyb
bors [Wed, 1 May 2019 09:32:58 +0000 (09:32 +0000)]
Auto merge of #60195 - varkor:commontypes-to-common, r=eddyb

Split `CommonTypes` into `CommonTypes` and `CommonLifetimes`

The so-called "`CommonTypes`" contains more than just types.

r? @eddyb

5 years agoAuto merge of #60280 - varkor:const-param-invariance, r=eddyb
bors [Wed, 1 May 2019 03:06:13 +0000 (03:06 +0000)]
Auto merge of #60280 - varkor:const-param-invariance, r=eddyb

Fix indexing issue for const parameter invariance

We were previously not taking account of the parent parameters.

r? @eddyb
cc @Zoxc

5 years agoAuto merge of #60204 - jethrogb:jb/rtunwrap-debug-print, r=alexcrichton
bors [Tue, 30 Apr 2019 22:46:28 +0000 (22:46 +0000)]
Auto merge of #60204 - jethrogb:jb/rtunwrap-debug-print, r=alexcrichton

Debug-print error when using rtunwrap

When I added this macro a while back I didn't have a way to make it print the failure for all types that you might want to unwrap. Now, I came up with a solution.

5 years agoAuto merge of #60262 - michaelwoerister:pgo-preinlining-pass, r=alexcrichton
bors [Tue, 30 Apr 2019 19:52:13 +0000 (19:52 +0000)]
Auto merge of #60262 - michaelwoerister:pgo-preinlining-pass, r=alexcrichton

 PGO: Add a run-make test that makes sure that PGO profiling data is used by the compiler during optimizations.

From the tests comment section:
```
# This test makes sure that PGO profiling data leads to cold functions being
# marked as `cold` and hot functions with `inlinehint`.
# The test program contains an `if` were actual execution only ever takes the
# `else` branch. Accordingly, we expect the function that is never called to
# be marked as cold.
```

r? @alexcrichton

5 years agoWork around missing tac command on macOS in PGO run-make test.
Michael Woerister [Tue, 30 Apr 2019 15:38:01 +0000 (17:38 +0200)]
Work around missing tac command on macOS in PGO run-make test.

5 years agoAuto merge of #60416 - Centril:rollup-bbyyz9x, r=Centril
bors [Tue, 30 Apr 2019 15:19:40 +0000 (15:19 +0000)]
Auto merge of #60416 - Centril:rollup-bbyyz9x, r=Centril

Rollup of 7 pull requests

Successful merges:

 - #60344 (Don't try to render auto-trait bounds with any inference variables)
 - #60354 (Cleanup declare_features! for 'accepted' with a uniform style + sort them)
 - #60362 (Cleanup 'active' declare_features! with uniform style + sorting.)
 - #60382 (Revert "Update Source Code Pro fonts to version 2.030")
 - #60399 (Update clippy)
 - #60400 (Remove functions to simplify handling of feature(bind_by_move_pattern_guards))
 - #60408 (Add missing f16c_target_feature check to typeck collect)

Failed merges:

r? @ghost

5 years agoRollup merge of #60408 - gnzlbg:f16c2, r=Centril
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:33 +0000 (16:10 +0200)]
Rollup merge of #60408 - gnzlbg:f16c2, r=Centril

Add missing f16c_target_feature check to typeck collect

5 years agoRollup merge of #60400 - JohnTitor:simplify-feature, r=matthewjasper
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:31 +0000 (16:10 +0200)]
Rollup merge of #60400 - JohnTitor:simplify-feature, r=matthewjasper

Remove functions to simplify handling of feature(bind_by_move_pattern_guards)

Fixes #59192

r? @matthewjasper

5 years agoRollup merge of #60399 - Manishearth:clippyup, r=Manishearth
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:30 +0000 (16:10 +0200)]
Rollup merge of #60399 - Manishearth:clippyup, r=Manishearth

Update clippy

None

5 years agoRollup merge of #60382 - Manishearth:revert-code-font, r=GuillaumeGomez
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:29 +0000 (16:10 +0200)]
Rollup merge of #60382 - Manishearth:revert-code-font, r=GuillaumeGomez

Revert "Update Source Code Pro fonts to version 2.030"

Temporary fix for https://github.com/rust-lang/rust/issues/60365

https://github.com/rust-lang/rust/pull/60146 updated all fonts (not just the fonts that were buggy), however it looks like the new Source Code Pro is buggy.

We should test this out of tree: `cargo doc` on anything, replace the font in `target/doc`, and use `python -m SimpleHTTPServer` to see what's going on.

Till we figure that out, I'll just back this out.

r? @GuillaumeGomez

This reverts commit 6bafc58cedc6f409dbcd8919a25b2f5d425f42ae.

5 years agoRollup merge of #60362 - Centril:cleanup-declare-features-active, r=oli-obk
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:27 +0000 (16:10 +0200)]
Rollup merge of #60362 - Centril:cleanup-declare-features-active, r=oli-obk

Cleanup 'active' declare_features! with uniform style + sorting.

r? @oli-obk

(added the FIXME you wanted)
cc https://github.com/rust-lang/rust/pull/60354
cc https://github.com/rust-lang/rust/issues/60361

5 years agoRollup merge of #60354 - Centril:cleanup-declare-features-accepted, r=oli-obk
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:26 +0000 (16:10 +0200)]
Rollup merge of #60354 - Centril:cleanup-declare-features-accepted, r=oli-obk

Cleanup declare_features! for 'accepted' with a uniform style + sort them

r? @oli-obk

cc https://github.com/rust-lang/rust/pull/60362
cc https://github.com/rust-lang/rust/issues/60361

5 years agoRollup merge of #60344 - Aaron1011:fix/tower-hyper, r=eddyb
Mazdak Farrokhzad [Tue, 30 Apr 2019 14:10:25 +0000 (16:10 +0200)]
Rollup merge of #60344 - Aaron1011:fix/tower-hyper, r=eddyb

Don't try to render auto-trait bounds with any inference variables

Previously, we checked if the target of a projection type was itself an
inference variable. However, for Rustdoc rendering purposes, there's no
distinction between an inference variable ('_') and a type containing
one (e.g. (MyStruct<u8, _>)) - we don't want to render either of them.

Fixes #60269

Due to the complexity of the original bug, which spans three different
crates (hyper, tower-hyper, and tower), I have been unable to create a
minimized reproduction for the issue.

5 years agoAuto merge of #60159 - estebank:type-mismatch-cast, r=oli-obk
bors [Tue, 30 Apr 2019 12:28:11 +0000 (12:28 +0000)]
Auto merge of #60159 - estebank:type-mismatch-cast, r=oli-obk

Suggest `try_into` when possible

CC #47168

5 years agoAdd missing f16c_target_feature check to typeck collect
gnzlbg [Tue, 30 Apr 2019 10:32:34 +0000 (12:32 +0200)]
Add missing f16c_target_feature check to typeck collect

5 years agoAdd local LLD to the PATH for run-make-fulldeps tests.
Michael Woerister [Tue, 30 Apr 2019 08:01:54 +0000 (10:01 +0200)]
Add local LLD to the PATH for run-make-fulldeps tests.

5 years agoRemove functions to simplify
Yuki OKUSHI [Tue, 30 Apr 2019 06:25:37 +0000 (15:25 +0900)]
Remove functions to simplify

5 years agoUpdate clippy
Manish Goregaokar [Tue, 30 Apr 2019 05:37:00 +0000 (22:37 -0700)]
Update clippy

5 years agoAuto merge of #60389 - Centril:rollup-nefreyr, r=Centril
bors [Tue, 30 Apr 2019 02:27:07 +0000 (02:27 +0000)]
Auto merge of #60389 - Centril:rollup-nefreyr, r=Centril

Rollup of 4 pull requests

Successful merges:

 - #59869 (SGX target: implemented vectored I/O)
 - #60238 (Update rustfmt to 1.2.2)
 - #60276 (Cleanup the MIR visitor)
 - #60380 (Fix line number display in source view)

Failed merges:

r? @ghost

5 years agoRollup merge of #60380 - GuillaumeGomez:fix-line-number-display, r=Manishearth
Mazdak Farrokhzad [Tue, 30 Apr 2019 01:28:39 +0000 (03:28 +0200)]
Rollup merge of #60380 - GuillaumeGomez:fix-line-number-display, r=Manishearth

Fix line number display in source view

Fixes #60310.

r? rust-lang/rustdoc

cc @Manishearth

screenshot of the fix:

<img width="798" alt="Screenshot 2019-04-29 at 23 12 20" src="https://user-images.githubusercontent.com/3050060/56927541-b7286680-6ad4-11e9-9215-42dc4ef42691.png">

5 years agoRollup merge of #60276 - matthewjasper:cleanup-mir-visitor, r=estebank
Mazdak Farrokhzad [Tue, 30 Apr 2019 01:28:38 +0000 (03:28 +0200)]
Rollup merge of #60276 - matthewjasper:cleanup-mir-visitor, r=estebank

Cleanup the MIR visitor

* Remove useless `BasicBlock` parameters on methods with `Location`s.
* Prefer `visit_terminator_kind` to `visit_terminator`.
* Remove `Region` from PlaceContexts. `visit_rvalue` should be used when the region is important.
* Remove unused visitor methods.

5 years agoRollup merge of #60238 - topecongiro:rustfmt-1.2.2, r=alexcrichton
Mazdak Farrokhzad [Tue, 30 Apr 2019 01:28:37 +0000 (03:28 +0200)]
Rollup merge of #60238 - topecongiro:rustfmt-1.2.2, r=alexcrichton

Update rustfmt to 1.2.2

5 years agoRollup merge of #59869 - jethrogb:jb/sgx-iovec, r=sfackler
Mazdak Farrokhzad [Tue, 30 Apr 2019 01:28:35 +0000 (03:28 +0200)]
Rollup merge of #59869 - jethrogb:jb/sgx-iovec, r=sfackler

SGX target: implemented vectored I/O

r? @sfackler

Includes #59857

5 years agoCleanup 'active' declare_features! with uniform style + sorting.
Mazdak Farrokhzad [Sun, 28 Apr 2019 23:46:45 +0000 (01:46 +0200)]
Cleanup 'active' declare_features! with uniform style + sorting.

5 years agoAccount for const fns to avoid incorrect suggestions
Esteban Küber [Tue, 30 Apr 2019 00:14:31 +0000 (17:14 -0700)]
Account for const fns to avoid incorrect suggestions

5 years agoSGX target: implemented vectored I/O
Jethro Beekman [Thu, 11 Apr 2019 02:47:10 +0000 (19:47 -0700)]
SGX target: implemented vectored I/O

5 years agoSGX target: don't unwind on usercall index out of bounds
Jethro Beekman [Thu, 11 Apr 2019 02:46:29 +0000 (19:46 -0700)]
SGX target: don't unwind on usercall index out of bounds

5 years agoAuto merge of #60006 - nnethercote:json-for-pipelining, r=alexcrichton
bors [Mon, 29 Apr 2019 23:35:01 +0000 (23:35 +0000)]
Auto merge of #60006 - nnethercote:json-for-pipelining, r=alexcrichton

In JSON output, emit a directive after metadata is generated.

To implement pipelining, Cargo needs to know when metadata generation is
finished. This is done via a new JSON "directive".

Unfortunately, metadata file writing currently occurs very late during
compilation, so pipelining won't produce a speed-up. Moving metadata
file writing earlier will be a follow-up.

r? @alexcrichton

5 years agoIn JSON output, emit a directive after metadata is generated.
Nicholas Nethercote [Sun, 14 Apr 2019 22:26:08 +0000 (08:26 +1000)]
In JSON output, emit a directive after metadata is generated.

To implement pipelining, Cargo needs to know when metadata generation is
finished. This commit adds code to do that. Unfortunately, metadata file
writing currently occurs very late during compilation, so pipelining
won't produce a speed-up. Moving metadata file writing earlier will be a
follow-up.

The change involves splitting the existing `Emitter::emit` method in
two: `Emitter::emit_diagnostic` and `Emitter::emit_directive`.

The JSON directives look like this:
```
{"directive":"metadata file written: liba.rmeta"}
```
The functionality is behind the `-Z emit-directives` option, and also
requires `--error-format=json`.

5 years agoAdd test
Esteban Küber [Sun, 21 Apr 2019 22:57:00 +0000 (15:57 -0700)]
Add test

5 years agoSuggest try_into when possible
Esteban Küber [Sun, 21 Apr 2019 22:44:23 +0000 (15:44 -0700)]
Suggest try_into when possible

5 years agoRevert "Update Source Code Pro fonts to version 2.030"
Manish Goregaokar [Mon, 29 Apr 2019 21:15:28 +0000 (14:15 -0700)]
Revert "Update Source Code Pro fonts to version 2.030"

This reverts commit 6bafc58cedc6f409dbcd8919a25b2f5d425f42ae.

5 years agoFix line number display in source view
Guillaume Gomez [Mon, 29 Apr 2019 21:13:30 +0000 (23:13 +0200)]
Fix line number display in source view

5 years agoAuto merge of #60377 - Centril:rollup-42fxe9u, r=Centril
bors [Mon, 29 Apr 2019 20:40:49 +0000 (20:40 +0000)]
Auto merge of #60377 - Centril:rollup-42fxe9u, r=Centril

Rollup of 9 pull requests

Successful merges:

 - #59946 (Fix equivalent string in escape_default docs)
 - #60256 (Option::flatten)
 - #60305 (hir: remove LoweredNodeId)
 - #60334 (Stabilized vectored IO)
 - #60353 (Add test not to forget resolved ICE)
 - #60356 (Stabilize str::as_mut_ptr)
 - #60358 (Clarify the short explanation of E0207)
 - #60359 (resolve: Consider erroneous imports used to avoid duplicate diagnostics)
 - #60360 (Add test case for labeled break in const assignment)

Failed merges:

r? @ghost

5 years agoRollup merge of #60360 - rasendubi:const-labeled-break, r=Centril
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:46 +0000 (22:22 +0200)]
Rollup merge of #60360 - rasendubi:const-labeled-break, r=Centril

Add test case for labeled break in const assignment

Fixes #51350.

5 years agoRollup merge of #60359 - petrochenkov:imperruse, r=estebank
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:45 +0000 (22:22 +0200)]
Rollup merge of #60359 - petrochenkov:imperruse, r=estebank

resolve: Consider erroneous imports used to avoid duplicate diagnostics

Supersedes https://github.com/rust-lang/rust/pull/60295
Fixes https://github.com/rust-lang/rust/issues/48244
r? @estebank

5 years agoRollup merge of #60358 - nickolay:patch-1, r=GuillaumeGomez
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:44 +0000 (22:22 +0200)]
Rollup merge of #60358 - nickolay:patch-1, r=GuillaumeGomez

Clarify the short explanation of E0207

After being greatly improved in #33692, https://doc.rust-lang.org/error-index.html#E0207 uses terminology from the related RFC, which is different from the [reference](https://doc.rust-lang.org/reference/items/implementations.html), e.g. "self type" instead of "implementing type" and "trait reference" instead of "implemented trait".

It probably makes no difference to an experienced reader, but for a newbie like me it added to the confusion as you can't look up the definition of the terms being used and can't be sure you've guessed correctly...

I would also move the link to RFC to the top, as it seems to be the only doc that attempts to explain what the third criteria entails), but it seems to go against the accepted style.

5 years agoRollup merge of #60356 - JohnTitor:stabilize-as-mut-ptr, r=Centril
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:42 +0000 (22:22 +0200)]
Rollup merge of #60356 - JohnTitor:stabilize-as-mut-ptr, r=Centril

Stabilize str::as_mut_ptr

Closes #58215

5 years agoRollup merge of #60353 - JohnTitor:add-test, r=Centril
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:41 +0000 (22:22 +0200)]
Rollup merge of #60353 - JohnTitor:add-test, r=Centril

Add test not to forget resolved ICE

closes #55499

I added the example as a test.

r? @pnkfelix

5 years agoRollup merge of #60334 - sfackler:stable-iovec, r=alexcrichton
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:40 +0000 (22:22 +0200)]
Rollup merge of #60334 - sfackler:stable-iovec, r=alexcrichton

Stabilized vectored IO

This renames `std::io::IoVec` to `std::io::IoSlice` and
`std::io::IoVecMut` to `std::io::IoSliceMut`, and stabilizes
`std::io::IoSlice`, `std::io::IoSliceMut`,
`std::io::Read::read_vectored`, and `std::io::Write::write_vectored`.

Closes #58452

r? @alexcrichton

5 years agoRollup merge of #60305 - ljedrz:remove_LoweredNodeId, r=Zoxc
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:38 +0000 (22:22 +0200)]
Rollup merge of #60305 - ljedrz:remove_LoweredNodeId, r=Zoxc

hir: remove LoweredNodeId

It seems that we no longer need it, because nowadays we just want the `HirId` most of the time.

5 years agoRollup merge of #60256 - ethanboxx:master, r=alexcrichton
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:36 +0000 (22:22 +0200)]
Rollup merge of #60256 - ethanboxx:master, r=alexcrichton

Option::flatten

This PR makes this possible.
```rust
assert_eq!(Some(6), Some(Some(6)).flatten());
assert_eq!(Some(6), Some(Some(6)).into());
```

5 years agoRollup merge of #59946 - mernen:patch-2, r=ehuss
Mazdak Farrokhzad [Mon, 29 Apr 2019 20:22:34 +0000 (22:22 +0200)]
Rollup merge of #59946 - mernen:patch-2, r=ehuss

Fix equivalent string in escape_default docs

This newline should be escaped.

5 years agoAuto merge of #60355 - Manishearth:clippyup, r=centril
bors [Mon, 29 Apr 2019 17:44:15 +0000 (17:44 +0000)]
Auto merge of #60355 - Manishearth:clippyup, r=centril

Update clippy

r? @centril

5 years agoUpdate clippy
Manish Goregaokar [Mon, 29 Apr 2019 05:34:51 +0000 (22:34 -0700)]
Update clippy

5 years agoAuto merge of #60039 - rasendubi:assert-trailing-junk, r=alexcrichton
bors [Mon, 29 Apr 2019 14:50:17 +0000 (14:50 +0000)]
Auto merge of #60039 - rasendubi:assert-trailing-junk, r=alexcrichton

Make assert! ensure the macro is parsed completely

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

5 years agobootstrap: Don't add LLVM's bin directory to the PATH for tool invocations.
Michael Woerister [Mon, 29 Apr 2019 12:40:07 +0000 (14:40 +0200)]
bootstrap: Don't add LLVM's bin directory to the PATH for tool invocations.

5 years agocompiletest: Make LLVM's bin directory available to run-make-fulldeps tests.
Michael Woerister [Mon, 29 Apr 2019 12:38:25 +0000 (14:38 +0200)]
compiletest: Make LLVM's bin directory available to run-make-fulldeps tests.

5 years agohir: remove LoweredNodeId
ljedrz [Fri, 26 Apr 2019 12:23:30 +0000 (14:23 +0200)]
hir: remove LoweredNodeId

5 years agoAuto merge of #60364 - JohnTitor:stabilize-const-needs-drop, r=oli-obk
bors [Mon, 29 Apr 2019 09:48:11 +0000 (09:48 +0000)]
Auto merge of #60364 - JohnTitor:stabilize-const-needs-drop, r=oli-obk

const-stabilize: std::mem::needs_drop

Closes #51929

r? @oli-obk

5 years agoAuto merge of #60338 - petrochenkov:notidy, r=varkor
bors [Mon, 29 Apr 2019 05:18:12 +0000 (05:18 +0000)]
Auto merge of #60338 - petrochenkov:notidy, r=varkor

tidy: Fix some more false positives for long URLs

A URL that's simply longer than 100 characters is ok regardless of context.

r? @varkor

5 years agoconst-stabilize std::mem::needs_drop
Yuki OKUSHI [Mon, 29 Apr 2019 03:41:06 +0000 (12:41 +0900)]
const-stabilize std::mem::needs_drop

5 years agoAuto merge of #60182 - matklad:lexer-cleanup, r=petrochenkov
bors [Mon, 29 Apr 2019 01:22:12 +0000 (01:22 +0000)]
Auto merge of #60182 - matklad:lexer-cleanup, r=petrochenkov

Lexer cleanup

another couple of tiny cleanups

5 years agoAuto merge of #60317 - flip1995:internal_lints, r=oli-obk
bors [Sun, 28 Apr 2019 20:42:09 +0000 (20:42 +0000)]
Auto merge of #60317 - flip1995:internal_lints, r=oli-obk

Internal lints: usage_of_qualified_ty & ty_pass_by_reference

Closes #59952

Implements internal lints:

- `USAGE_OF_QUALIFIED_TY`
- `TY_PASS_BY_REFERENCE`

r? @oli-obk

5 years agoRemove unused TyCtxt argument from allow_two_phase_borrow function
flip1995 [Sun, 28 Apr 2019 19:13:33 +0000 (21:13 +0200)]
Remove unused TyCtxt argument from allow_two_phase_borrow function

5 years agoAdd test case for labeled break in const assignment
Alexey Shmalko [Sun, 28 Apr 2019 20:12:35 +0000 (23:12 +0300)]
Add test case for labeled break in const assignment

See https://github.com/rust-lang/rust/issues/51350 for more information.

5 years agoClarify the short explanation of E0207
Nickolay Ponomarev [Sun, 28 Apr 2019 19:32:28 +0000 (22:32 +0300)]
Clarify the short explanation of E0207

- Use the terms from the reference <https://doc.rust-lang.org/reference/items/implementations.html>
- Add code snippets to explain the terms

5 years agoresolve: Consider erroneous imports used to avoid duplicate diagnostics
Vadim Petrochenkov [Sun, 28 Apr 2019 18:27:01 +0000 (21:27 +0300)]
resolve: Consider erroneous imports used to avoid duplicate diagnostics

5 years agoFix lint findings in librustdoc
flip1995 [Sat, 27 Apr 2019 16:37:18 +0000 (18:37 +0200)]
Fix lint findings in librustdoc

5 years agoFix lint findings in librustc_mir
flip1995 [Fri, 26 Apr 2019 12:26:49 +0000 (14:26 +0200)]
Fix lint findings in librustc_mir

5 years agoFix lint findings in librustc_traits
flip1995 [Fri, 26 Apr 2019 12:10:46 +0000 (14:10 +0200)]
Fix lint findings in librustc_traits

5 years agoFix lint findings in librustc_typeck
flip1995 [Fri, 26 Apr 2019 11:41:10 +0000 (13:41 +0200)]
Fix lint findings in librustc_typeck

5 years agoFix lint findings in librustc_metadata
flip1995 [Fri, 26 Apr 2019 09:44:42 +0000 (11:44 +0200)]
Fix lint findings in librustc_metadata

5 years agoFix lint findings in librustc
flip1995 [Thu, 25 Apr 2019 20:54:19 +0000 (22:54 +0200)]
Fix lint findings in librustc

5 years agoUpdate *.stderr files
flip1995 [Wed, 24 Apr 2019 21:24:00 +0000 (23:24 +0200)]
Update *.stderr files

5 years agoAdd tests
flip1995 [Wed, 24 Apr 2019 21:23:44 +0000 (23:23 +0200)]
Add tests

5 years agoImplement internal lints
flip1995 [Wed, 24 Apr 2019 21:22:54 +0000 (23:22 +0200)]
Implement internal lints

- USAGE_OF_QUALIFIED_TY

- TY_PASS_BY_REFERENCE

5 years agoStabilize str::as_mut_ptr
Yuki OKUSHI [Sun, 28 Apr 2019 17:33:50 +0000 (02:33 +0900)]
Stabilize str::as_mut_ptr

5 years agoAuto merge of #60352 - Centril:const-incomplete-features, r=oli-obk
bors [Sun, 28 Apr 2019 15:40:00 +0000 (15:40 +0000)]
Auto merge of #60352 - Centril:const-incomplete-features, r=oli-obk

Float 'incomplete_features' out to a const for visibility

Float `let incomplete_features` out to a `const INCOMPLETE_FEATURES` and colocate near `active` features so that it is easier to find and edit.

r? @oli-obk

(use rollup)

5 years agoCleanup declare_features! for 'accepted' with a uniform style + sort them.
Mazdak Farrokhzad [Sun, 28 Apr 2019 14:14:21 +0000 (16:14 +0200)]
Cleanup declare_features! for 'accepted' with a uniform style + sort them.

5 years agoAdd test
Yuki OKUSHI [Sun, 28 Apr 2019 13:54:06 +0000 (22:54 +0900)]
Add test

5 years agoFloat 'incomplete_features' out to a const for visibility.
Mazdak Farrokhzad [Sun, 28 Apr 2019 13:13:35 +0000 (15:13 +0200)]
Float 'incomplete_features' out to a const for visibility.

5 years agoAuto merge of #60351 - Centril:rollup-5xv3tka, r=Centril
bors [Sun, 28 Apr 2019 12:50:06 +0000 (12:50 +0000)]
Auto merge of #60351 - Centril:rollup-5xv3tka, r=Centril

Rollup of 4 pull requests

Successful merges:

 - #60022 (Document `Item` type in `std::env::SplitPaths` iterator.)
 - #60270 (rustc: Flag metadata compatible with multiple CGUs)
 - #60325 (Document ast::ExprKind::Type)
 - #60347 (Remove `-Z two-phase-borrows` and `-Z two-phase-beyond-autoref`)

Failed merges:

r? @ghost

5 years agoRollup merge of #60347 - JohnTitor:remove-flags, r=matthewjasper
Mazdak Farrokhzad [Sun, 28 Apr 2019 12:17:12 +0000 (14:17 +0200)]
Rollup merge of #60347 - JohnTitor:remove-flags, r=matthewjasper

Remove `-Z two-phase-borrows` and `-Z two-phase-beyond-autoref`

fixes #60331

5 years agoRollup merge of #60325 - Centril:doc-ast-exprkind-type, r=oli-obk
Mazdak Farrokhzad [Sun, 28 Apr 2019 12:17:11 +0000 (14:17 +0200)]
Rollup merge of #60325 - Centril:doc-ast-exprkind-type, r=oli-obk

Document ast::ExprKind::Type

r? @oli-obk

5 years agoRollup merge of #60270 - alexcrichton:metadata-multi-cgu, r=oli-obk
Mazdak Farrokhzad [Sun, 28 Apr 2019 12:17:10 +0000 (14:17 +0200)]
Rollup merge of #60270 - alexcrichton:metadata-multi-cgu, r=oli-obk

rustc: Flag metadata compatible with multiple CGUs

It looks like the `OutputType::Metadata` kind in the compiler was
misclassified in #38571 long ago by accident as incompatible with
codegen units and a single output file. This means that if you emit both
a linkable artifact and metadata it silently turns off multiple codegen
units unintentionally!

This commit corrects the situation to ensure that if `--emit metadata`
is used it doesn't implicitly disable multiple codegen units. This will
ensure we don't accidentally regress compiler performance when striving
to implement pipelined compilation!

5 years agoRollup merge of #60022 - nathankleyn:fix-issue-59543, r=Centril
Mazdak Farrokhzad [Sun, 28 Apr 2019 12:17:08 +0000 (14:17 +0200)]
Rollup merge of #60022 - nathankleyn:fix-issue-59543, r=Centril

Document `Item` type in `std::env::SplitPaths` iterator.

Previously there wasn't any documentation to show what the type of
`Item` was inside `std::env::SplitPaths`. Now, in the same format as
other examples of docs in `std` for `Iterator#Item`, we mention the
type.

This fixes #59543.

r? @steveklabnik

5 years agoRemove unnecessary function
Yuki OKUSHI [Sun, 28 Apr 2019 10:31:54 +0000 (19:31 +0900)]
Remove unnecessary function

5 years agoAuto merge of #60346 - dima74:patch-1, r=GuillaumeGomez
bors [Sun, 28 Apr 2019 09:58:59 +0000 (09:58 +0000)]
Auto merge of #60346 - dima74:patch-1, r=GuillaumeGomez

Fix default value for setting "Auto-hide item methods' documentation"

If I open any documentation page in incognito mode (for example [for `Option` enum](https://doc.rust-lang.org/nightly/std/option/enum.Option.html)), then methods will be collapsed, though [on the settings page](https://doc.rust-lang.org/nightly/settings.html) there will be displayed that "Auto-hide item methods' documentation" option is disabled.

If I understand correctly, property "Auto-hide item methods' documentation" [should be disabled by default](https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/render.rs#L1969), so correct check would be `property === "true"`. This is consistent with other options:

Options which are enabled by default are compared to `"false"`

https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/render.rs#L1965-L1968

https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/static/main.js#L2238
https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/static/main.js#L2321
https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/static/main.js#L2070

Options which are disabled by default are compared to `"true"`

https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/render.rs#L1970-L1972

https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/static/main.js#L1389
https://github.com/rust-lang/rust/blob/938d4ffe16c4430e1dcede570b06227114cb73d5/src/librustdoc/html/static/main.js#L2334

5 years agoRemove two-phase-beyond-autoref
Yuki OKUSHI [Sun, 28 Apr 2019 03:51:04 +0000 (12:51 +0900)]
Remove two-phase-beyond-autoref

5 years agoRemove two-phase-borrows
Yuki OKUSHI [Sun, 28 Apr 2019 03:22:47 +0000 (12:22 +0900)]
Remove two-phase-borrows

5 years agoAuto merge of #60333 - Centril:stabilize-iterator-copied, r=varkor
bors [Sun, 28 Apr 2019 01:46:11 +0000 (01:46 +0000)]
Auto merge of #60333 - Centril:stabilize-iterator-copied, r=varkor

Stabilize Iterator::copied in 1.36.0

Per https://github.com/rust-lang/rust/issues/57127#issuecomment-487289429.

Closes https://github.com/rust-lang/rust/issues/57127.

r? @varkor

5 years agoFix default value for setting "Auto-hide item methods' documentation"
Dmitry Murzin [Sun, 28 Apr 2019 01:25:22 +0000 (04:25 +0300)]
Fix default value for setting "Auto-hide item methods' documentation"

5 years agoDon't try to render auto-trait bounds with any inference variables
Aaron Hill [Sun, 28 Apr 2019 00:33:03 +0000 (20:33 -0400)]
Don't try to render auto-trait bounds with any inference variables

Previously, we checked if the target of a projection type was itself an
inference variable. However, for Rustdoc rendering purposes, there's no
distinction between an inference variable ('_') and a type containing
one (e.g. (MyStruct<u8, _>)) - we don't want to render either of them.

Fixes #60269

Due to the complexity of the original bug, which spans three different
crates (hyper, tower-hyper, and tower), I have been unable to create a
minimized reproduction for the issue.

5 years agoAuto merge of #60313 - cuviper:thinlto-import, r=alexcrichton
bors [Sat, 27 Apr 2019 19:53:00 +0000 (19:53 +0000)]
Auto merge of #60313 - cuviper:thinlto-import, r=alexcrichton

Limit internalization in LLVM 8 ThinLTO

Fixes #60184.
r? @alexcrichton

5 years agotidy: Fix false positives from long URLs
Vadim Petrochenkov [Sat, 27 Apr 2019 17:29:27 +0000 (20:29 +0300)]
tidy: Fix false positives from long URLs

5 years agoAuto merge of #60288 - Zoxc:update-rayon, r=nikomatsakis
bors [Sat, 27 Apr 2019 17:08:11 +0000 (17:08 +0000)]
Auto merge of #60288 - Zoxc:update-rayon, r=nikomatsakis

Update rustc-rayon version

r? @nikomatsakis

5 years agotidy
Steven Fackler [Sat, 27 Apr 2019 16:19:34 +0000 (09:19 -0700)]
tidy

5 years agoStabilized vectored IO
Steven Fackler [Sat, 27 Apr 2019 15:34:08 +0000 (08:34 -0700)]
Stabilized vectored IO

This renames `std::io::IoVec` to `std::io::IoSlice` and
`std::io::IoVecMut` to `std::io::IoSliceMut`, and stabilizes
`std::io::IoSlice`, `std::io::IoSliceMut`,
`std::io::Read::read_vectored`, and `std::io::Write::write_vectored`.

Closes #58452

5 years agoStabilize Iterator::copied in 1.36.0.
Mazdak Farrokhzad [Sat, 27 Apr 2019 14:45:30 +0000 (16:45 +0200)]
Stabilize Iterator::copied in 1.36.0.

5 years agoAuto merge of #60329 - Centril:rollup-wv8g1ex, r=Centril
bors [Sat, 27 Apr 2019 14:06:39 +0000 (14:06 +0000)]
Auto merge of #60329 - Centril:rollup-wv8g1ex, r=Centril

Rollup of 5 pull requests

Successful merges:

 - #60292 (Replace the `&'tcx List<Ty<'tcx>>` in `TyKind::Tuple` with `SubstsRef<'tcx>`)
 - #60307 (Make "Implementations on Foreign Types" items in sidebar link to specific impls)
 - #60309 (Add 1.34.1 release notes)
 - #60315 (bootstrap: use correct version numbers for llvm-tools and lldb)
 - #60316 (Use "capacity" as parameter name in with_capacity() methods)

Failed merges:

r? @ghost

5 years agoRollup merge of #60316 - mgeier:rename-capacity-parameter, r=joshtriplett
Mazdak Farrokhzad [Sat, 27 Apr 2019 12:12:42 +0000 (14:12 +0200)]
Rollup merge of #60316 - mgeier:rename-capacity-parameter, r=joshtriplett

Use "capacity" as parameter name in with_capacity() methods

See #60271.

The only place where I didn't change the parameter name is `RawVec`. The problem is that it has a `.cap()` method instead of the usual `.capacity()`:

https://github.com/rust-lang/rust/blob/597f432489f12a3f33419daa039ccef11a12c4fd/src/liballoc/raw_vec.rs#L200-L210

Changing this would be a breaking change, and I guess that's not worth it.

But since I didn't change `.cap()` there, I didn't change the `cap` parameter name to `capacity`, either.

5 years agoRollup merge of #60315 - pietroalbini:fix-tools-version, r=Mark-Simulacrum
Mazdak Farrokhzad [Sat, 27 Apr 2019 12:12:41 +0000 (14:12 +0200)]
Rollup merge of #60315 - pietroalbini:fix-tools-version, r=Mark-Simulacrum

bootstrap: use correct version numbers for llvm-tools and lldb

The current URLs for the `llvm-tools` and `lldb` components are a bit broken right now:

```
https://static.rust-lang.org/dist/2019-04-25/llvm-tools-1.34.1 (fc50f328b 2019-04-24)-aarch64-unknown-linux-gnu.tar.gz
```

This PR uses proper version numbers for those. Tested a dist build locally and everything works.

r? @Mark-Simulacrum

5 years agoRollup merge of #60309 - pietroalbini:relnotes-1.34.1, r=pietroalbini
Mazdak Farrokhzad [Sat, 27 Apr 2019 12:12:40 +0000 (14:12 +0200)]
Rollup merge of #60309 - pietroalbini:relnotes-1.34.1, r=pietroalbini

Add 1.34.1 release notes

This is a backport of the release notes from the 1.34.1 release.

r? @ghost

5 years agoRollup merge of #60307 - dima74:fix/56018, r=GuillaumeGomez
Mazdak Farrokhzad [Sat, 27 Apr 2019 12:12:38 +0000 (14:12 +0200)]
Rollup merge of #60307 - dima74:fix/56018, r=GuillaumeGomez

Make "Implementations on Foreign Types" items in sidebar link to specific impls

This solves #56018 for most cases (though not work for foreign impls with same names)

5 years agoRollup merge of #60292 - varkor:ty-tuple-substs, r=nikomatsakis
Mazdak Farrokhzad [Sat, 27 Apr 2019 12:12:37 +0000 (14:12 +0200)]
Rollup merge of #60292 - varkor:ty-tuple-substs, r=nikomatsakis

Replace the `&'tcx List<Ty<'tcx>>` in `TyKind::Tuple` with `SubstsRef<'tcx>`

Part of the suggested refactoring for https://github.com/rust-lang/rust/issues/42340. As expected, this is a little messy, because there are many places that the components of tuples are expected to be types, rather than arbitrary kinds. However, it should open up the way for a refactoring of `TyS` itself.

r? @nikomatsakis

5 years agoDocument ast::ExprKind::Type.
Mazdak Farrokhzad [Sat, 27 Apr 2019 10:06:02 +0000 (12:06 +0200)]
Document ast::ExprKind::Type.

5 years agoUpdate rustfmt to 1.2.2
topecongiro [Wed, 24 Apr 2019 15:38:34 +0000 (00:38 +0900)]
Update rustfmt to 1.2.2