]> git.lizzy.rs Git - rust.git/log
rust.git
5 years agoAuto merge of #61868 - Centril:rollup-gglsecp, r=Centril
bors [Sat, 15 Jun 2019 18:24:18 +0000 (18:24 +0000)]
Auto merge of #61868 - Centril:rollup-gglsecp, r=Centril

Rollup of 6 pull requests

Successful merges:

 - #61785 (note some safety concerns of raw-ptr-to-ref casts)
 - #61805 (typeck: Fix ICE for blocks in repeat expr count.)
 - #61813 (Remove some unnecessary symbol interner ops)
 - #61824 (in which we decline to lint single-use lifetimes in `derive`d impls)
 - #61844 (Change `...` to `..=` where applicable)
 - #61854 (Minor cosmetic improvements to accompany PR 61825)

Failed merges:

r? @ghost

5 years agocleanup some new active feature gates.
Mazdak Farrokhzad [Sat, 15 Jun 2019 17:00:49 +0000 (19:00 +0200)]
cleanup some new active feature gates.

5 years agoRollup merge of #61854 - alexreg:fix-type-alias-enum-patterns, r=Centril
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:45:07 +0000 (17:45 +0200)]
Rollup merge of #61854 - alexreg:fix-type-alias-enum-patterns, r=Centril

Minor cosmetic improvements to accompany PR 61825

r? @Centril

5 years agoRollup merge of #61844 - AaronKutch:master, r=Centril
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:45:06 +0000 (17:45 +0200)]
Rollup merge of #61844 - AaronKutch:master, r=Centril

Change `...` to `..=` where applicable

This is mainly to fix #61816, but I decided to manually check a few thousand `...` throughout the code base to check for any other cases. I think I found a documentation bug in `src\libsyntax\ast.rs` where both `1..` and `1...` where mentioned. If there is internal support for both `1..` and `1..=` (that can exist before error handling gets to it), then I can add that back.
There were some other cases that look like `// struct Closure<'l0...'li, T0...Tj, CK, CS, U0...Uk> {`, `// <P0 as Trait<P1...Pn>>::Foo: 'a`, and `assert!(min <= max, "discriminant range is {}...{}", min, max);`, but I am not sure if I should change those.
There are a bunch of cases in the `/test/` directory that could be changed, but I presume I should just leave those be.

5 years agoRollup merge of #61824 - rust-lang:single_derive, r=eddyb
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:45:04 +0000 (17:45 +0200)]
Rollup merge of #61824 - rust-lang:single_derive, r=eddyb

in which we decline to lint single-use lifetimes in `derive`d impls

Resolves #53738.

r? @eddyb

5 years agoRollup merge of #61813 - matthewjasper:remove-unnecessary-symbol-ops, r=petrochenkov
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:45:02 +0000 (17:45 +0200)]
Rollup merge of #61813 - matthewjasper:remove-unnecessary-symbol-ops, r=petrochenkov

Remove some unnecessary symbol interner ops

* Don't gensym symbols that don't need to worry about colliding with other symbols
* Use symbol constants instead of interning string literals in a few places.
* Don't generate a module in `__register_diagnostic`

r? @petrochenkov

5 years agoRollup merge of #61805 - davidtwco:ice-const-generic-repeat-expr-count-sequel, r...
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:45:01 +0000 (17:45 +0200)]
Rollup merge of #61805 - davidtwco:ice-const-generic-repeat-expr-count-sequel, r=varkor

typeck: Fix ICE for blocks in repeat expr count.

Fixes #61336 (again). This PR fixes an ICE that occured when a block expression resolving to a const generic was used for the count of an array repeat expression.

r? @varkor

5 years agoRollup merge of #61785 - RalfJung:as-ref, r=rkruppe
Mazdak Farrokhzad [Sat, 15 Jun 2019 15:44:59 +0000 (17:44 +0200)]
Rollup merge of #61785 - RalfJung:as-ref, r=rkruppe

note some safety concerns of raw-ptr-to-ref casts

5 years agoAuto merge of #61143 - estebank:issue-61106, r=eddyb
bors [Sat, 15 Jun 2019 13:12:13 +0000 (13:12 +0000)]
Auto merge of #61143 - estebank:issue-61106, r=eddyb

When suggesting borrow, remove useless clones

Fix #61106.

5 years agoRemove unnecessary `.clone()`
Shotaro Yamada [Sat, 8 Jun 2019 10:06:58 +0000 (19:06 +0900)]
Remove unnecessary `.clone()`

5 years agoUse `slice::from_ref` instead of cloning
Shotaro Yamada [Sat, 8 Jun 2019 09:37:37 +0000 (18:37 +0900)]
Use `slice::from_ref` instead of cloning

5 years agoAuto merge of #59752 - Zoxc:dylib-fix, r=alexcrichton
bors [Sat, 15 Jun 2019 10:18:09 +0000 (10:18 +0000)]
Auto merge of #59752 - Zoxc:dylib-fix, r=alexcrichton

Limit dylib symbols

This makes `windows-gnu` match the behavior of `windows-msvc`. It probably doesn't make sense to export these symbols on other platforms either.

5 years agoAuto merge of #61825 - Centril:tauv-infer-fix, r=petrochenkov
bors [Sat, 15 Jun 2019 03:47:55 +0000 (03:47 +0000)]
Auto merge of #61825 - Centril:tauv-infer-fix, r=petrochenkov

type_alias_enum_variants: fix #61801; allow a path pattern to infer

Fix #61801.

Given a type-relative path pattern referring to an enum variant through a type alias, allow inferring the generic argument applied in the expectation set by the scrutinee of a `match` expression.

Similar issues may exist for `let` statements but I don't know how to test for that since `PhantomData<T>` is necessary...)

The gist of the problem here was that `resolve_ty_and_res_ufcs` was called twice which is apparently no good... It is possible that this PR is papering over some deeper problem, but that is beyond my knowledge of the compiler.

r? @petrochenkov
cc @eddyb @alexreg
cc https://github.com/rust-lang/rust/pull/61682
cc https://github.com/rust-lang/rust/issues/49683

5 years agotypeck/expr.rs: move check_field + struct helpers here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 01:32:16 +0000 (03:32 +0200)]
typeck/expr.rs: move check_field + struct helpers here.

5 years agotypeck/expr.rs: move check_method_call here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 01:11:36 +0000 (03:11 +0200)]
typeck/expr.rs: move check_method_call here.

5 years agotypeck/expr.rs: move some check_return_expr here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 01:01:05 +0000 (03:01 +0200)]
typeck/expr.rs: move some check_return_expr here.

5 years agotypeck/expr.rs: move some check_expr_*s here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:58:32 +0000 (02:58 +0200)]
typeck/expr.rs: move some check_expr_*s here.

5 years agotypeck/expr.rs: move check_expr_with_expectation_and_needs here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:51:45 +0000 (02:51 +0200)]
typeck/expr.rs: move check_expr_with_expectation_and_needs here.

5 years agotypeck/expr.rs: extract out check_expr_yield.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:48:59 +0000 (02:48 +0200)]
typeck/expr.rs: extract out check_expr_yield.

5 years agotypeck/expr.rs: extract out check_expr_index.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:46:47 +0000 (02:46 +0200)]
typeck/expr.rs: extract out check_expr_index.

5 years agotypeck/expr.rs: move check_expr_struct here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:43:02 +0000 (02:43 +0200)]
typeck/expr.rs: move check_expr_struct here.

5 years agotypeck/expr.rs: extract out check_expr_tuple.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:39:23 +0000 (02:39 +0200)]
typeck/expr.rs: extract out check_expr_tuple.

5 years agotypeck/expr.rs: extract out check_expr_repeat.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:36:07 +0000 (02:36 +0200)]
typeck/expr.rs: extract out check_expr_repeat.

5 years agotypeck/expr.rs: extract out check_expr_array.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:31:20 +0000 (02:31 +0200)]
typeck/expr.rs: extract out check_expr_array.

5 years agotypeck/expr.rs: extract out check_expr_cast.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:25:37 +0000 (02:25 +0200)]
typeck/expr.rs: extract out check_expr_cast.

5 years agotypeck/expr.rs: extract out check_expr_loop.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:22:52 +0000 (02:22 +0200)]
typeck/expr.rs: extract out check_expr_loop.

5 years agotypeck/expr.rs: extract out check_expr_while.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:19:23 +0000 (02:19 +0200)]
typeck/expr.rs: extract out check_expr_while.

5 years agotypeck/expr.rs: move check_expr_assign here.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:10:56 +0000 (02:10 +0200)]
typeck/expr.rs: move check_expr_assign here.

5 years agotypeck/expr.rs: extract out check_expr_return.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:10:12 +0000 (02:10 +0200)]
typeck/expr.rs: extract out check_expr_return.

5 years agotypeck/expr.rs: extract out check_expr_break.
Mazdak Farrokhzad [Sat, 15 Jun 2019 00:06:02 +0000 (02:06 +0200)]
typeck/expr.rs: extract out check_expr_break.

5 years agotypeck/expr.rs: extract out check_expr_path.
Mazdak Farrokhzad [Fri, 14 Jun 2019 23:56:10 +0000 (01:56 +0200)]
typeck/expr.rs: extract out check_expr_path.

5 years agotypeck/expr.rs: extract out check_expr_addr_of.
Mazdak Farrokhzad [Fri, 14 Jun 2019 23:50:33 +0000 (01:50 +0200)]
typeck/expr.rs: extract out check_expr_addr_of.

5 years agotypeck/expr.rs: extract out check_expr_unary.
Mazdak Farrokhzad [Fri, 14 Jun 2019 23:45:39 +0000 (01:45 +0200)]
typeck/expr.rs: extract out check_expr_unary.

5 years agotypeck/expr.rs: extract out check_expr_box.
Mazdak Farrokhzad [Fri, 14 Jun 2019 23:36:09 +0000 (01:36 +0200)]
typeck/expr.rs: extract out check_expr_box.

5 years agotypeck: check_expr_kind -> expr.rs
Mazdak Farrokhzad [Fri, 14 Jun 2019 23:28:38 +0000 (01:28 +0200)]
typeck: check_expr_kind -> expr.rs

5 years agoMinor cosmetic improvements to accompany PR 61825
Alexander Regueiro [Fri, 14 Jun 2019 22:43:23 +0000 (23:43 +0100)]
Minor cosmetic improvements to accompany PR 61825

5 years agoreview comments: move diagnostic code out of happy path
Esteban Küber [Wed, 12 Jun 2019 01:21:53 +0000 (18:21 -0700)]
review comments: move diagnostic code out of happy path

5 years agoTweak transparent enums and unions diagnostic spans
Esteban Küber [Tue, 11 Jun 2019 20:28:22 +0000 (13:28 -0700)]
Tweak transparent enums and unions diagnostic spans

5 years agoupdate miri
Ralf Jung [Fri, 14 Jun 2019 19:58:33 +0000 (21:58 +0200)]
update miri

5 years agoRemove unnecessary lift calls
John Kåre Alsaker [Fri, 14 Jun 2019 16:09:57 +0000 (18:09 +0200)]
Remove unnecessary lift calls

5 years agoreview comment: do not rely on path str to identify std::clone::Clone
Esteban Küber [Fri, 14 Jun 2019 18:44:20 +0000 (11:44 -0700)]
review comment: do not rely on path str to identify std::clone::Clone

5 years agoUse `sym` constansts for `PrimitiveTypeTable` keys
Matthew Jasper [Thu, 13 Jun 2019 20:14:58 +0000 (21:14 +0100)]
Use `sym` constansts for `PrimitiveTypeTable` keys

5 years agoAvoid some unnecessary symbol interner operations
Matthew Jasper [Tue, 11 Jun 2019 18:47:52 +0000 (19:47 +0100)]
Avoid some unnecessary symbol interner operations

5 years agoreview comments: avoid string modification
Esteban Küber [Fri, 14 Jun 2019 17:45:13 +0000 (10:45 -0700)]
review comments: avoid string modification

5 years agoChange `...` to `..=` where applicable
Aaron Kutch [Fri, 14 Jun 2019 17:24:38 +0000 (12:24 -0500)]
Change `...` to `..=` where applicable

5 years agoTurn down the myriad-closures test
Alex Crichton [Fri, 14 Jun 2019 16:53:59 +0000 (09:53 -0700)]
Turn down the myriad-closures test

This tests takes nearly 5 minutes to compile on CI where the CPUs we
have aren't exactly the fastest. This test does actually require all
closures to exist to exhibit the original bug, but it seems a little
excessive to test a single bug on CI on all platforms which simply pegs
a single CPU for 5 minutes with no parallelism opportunities, so this
turns down the test to still exercise it somewhat at least.

5 years agoAuto merge of #61817 - eddyb:begone-gcx-attempt-2, r=oli-obk
bors [Fri, 14 Jun 2019 16:20:35 +0000 (16:20 +0000)]
Auto merge of #61817 - eddyb:begone-gcx-attempt-2, r=oli-obk

Unify all uses of 'gcx and 'tcx.

This is made possible by @Zoxc landing #57214 (see https://github.com/rust-lang/rust/pull/57214#issuecomment-465036053 for the decision).

A bit of context for the approach: just like #61722, this is *not* how I originally intended to go about this, but @Zoxc and my own experimentation independently resulted in the same conclusion:
The interim alias `type TyCx<'tcx> = TyCtxt<'tcx, 'tcx>;` attempt required more work (adding `use`s), even only for handling the `TyCtxt<'tcx, 'tcx>` case and not the general `TyCtxt<'gcx, 'tcx>` one.

What this PR is based on is the realization that `'gcx` is a special-enough name that it can be replaced, without caring for context, with `'tcx`, and then repetitions of the name `'tcx` be compacted away.
After that, only a small number of error categories remained, each category easily dealt with with either more mass replacements (e.g. `TyCtxt<'tcx, '_>` -> `TyCtxt<'tcx>`) or by hand.

For the `rustfmt` commit, I used https://github.com/rust-lang/rustfmt/issues/1324#issuecomment-482109952, and manually filtered out some noise, like in #61735 and #61722, and like the latter, there was also a weird bug to work around.
It should be reviewed separately, and dropped if unwanted (in this PR it's pretty significant).

cc @rust-lang/compiler r? @nikomatsakis

5 years agoRun `rustfmt --file-lines ...` for changes from previous commits.
Eduard-Mihai Burtescu [Thu, 13 Jun 2019 22:32:15 +0000 (01:32 +0300)]
Run `rustfmt --file-lines ...` for changes from previous commits.

5 years agoUnify all uses of 'gcx and 'tcx.
Eduard-Mihai Burtescu [Thu, 13 Jun 2019 21:48:52 +0000 (00:48 +0300)]
Unify all uses of 'gcx and 'tcx.

5 years agoAuto merge of #61421 - vorner:string-in-rc-into-raw-docs, r=RalfJung
bors [Fri, 14 Jun 2019 12:37:28 +0000 (12:37 +0000)]
Auto merge of #61421 - vorner:string-in-rc-into-raw-docs, r=RalfJung

docs: Use String in Rc::into_raw examples

It is unclear if accessing an integer after `drop_in_place` has been
called on it is undefined behaviour or not, as demonstrated by the
discussion in
https://github.com/rust-lang/rust/pull/60766#pullrequestreview-243414222.

Avoid these uncertainties by using String which frees memory in its
`drop_in_place` to make sure this is undefined behaviour. The message in
the docs should be to watch out and not access the data after that, not
discussing when one maybe could get away with it O:-).

5 years agoFix examples
Yuki Okushi [Fri, 14 Jun 2019 11:12:01 +0000 (20:12 +0900)]
Fix examples

5 years agoput back the workarounds for #60846
Felix S Klock II [Fri, 14 Jun 2019 10:19:26 +0000 (12:19 +0200)]
put back the workarounds for #60846

based on https://github.com/rust-lang/rust/pull/61754#issuecomment-501743750 I am adding `bootstrap` to the cfg-preconditions for the two manual `unsafe impls`'s of `Send` and `Sync` for `TokenTree`.

5 years agoAuto merge of #61679 - zackmdavis:maybe_dont_indicate_the_anonymous_lifetime, r=oli-obk
bors [Fri, 14 Jun 2019 09:39:17 +0000 (09:39 +0000)]
Auto merge of #61679 - zackmdavis:maybe_dont_indicate_the_anonymous_lifetime, r=oli-obk

in which we decline to suggest the anonymous lifetime in declarations

The elided-lifetimes-in-path lint (part of our suite of Rust 2018 idiom lints which we are hoping to promote to Warn status) was firing with an illegal suggestion to write an anonymous lifetime in a
struct/item declaration (where we don't allow it). The linting code was already deciding whether to act on the basis of a `ParamMode` enum, indicating whether the present path-segment was part of an
expression, or anywhere else. The present case seemed to be part of the "anywhere else", and yet meriting different rules as far as the lint was concerned, so it seemed expedient to introduce a new enum member. We yank out `TyKind::Path` arm into its own method so that we can call it with our new `ParamMode` specifically when lowering struct fields—one would have hoped to think of something more elegant than this, but it definitely beats changing the signature of `lower_ty` to take a `ParamMode`!

Resolves #61124.

cc @memoryruins
r? @oli-obk

5 years agorustbuild: include llvm-libunwind in dist tarball
Marc-Antoine Perennou [Fri, 14 Jun 2019 09:24:59 +0000 (11:24 +0200)]
rustbuild: include llvm-libunwind in dist tarball

Signed-off-by: Marc-Antoine Perennou <Marc-Antoine@Perennou.com>
5 years agomake sure we use cfg-if as a std dependency
Ralf Jung [Fri, 14 Jun 2019 09:00:37 +0000 (11:00 +0200)]
make sure we use cfg-if as a std dependency

5 years agonote some safety concerns of raw-ptr-to-ref casts
Ralf Jung [Wed, 12 Jun 2019 21:23:34 +0000 (23:23 +0200)]
note some safety concerns of raw-ptr-to-ref casts

5 years agotype_alias_enum_variants: add regression test for #61801.
Mazdak Farrokhzad [Fri, 14 Jun 2019 07:16:39 +0000 (09:16 +0200)]
type_alias_enum_variants: add regression test for #61801.

5 years agoin which we decline to lint single-use lifetimes in `derive`d impls
Zack M. Davis [Fri, 14 Jun 2019 06:16:47 +0000 (23:16 -0700)]
in which we decline to lint single-use lifetimes in `derive`d impls

Resolves #53738.

5 years agoin which we decline to suggest the anonymous lifetime in declarations
Zack M. Davis [Sun, 9 Jun 2019 04:35:02 +0000 (21:35 -0700)]
in which we decline to suggest the anonymous lifetime in declarations

The elided-lifetimes-in-path lint (part of our suite of Rust 2018
idiom lints which we are hoping to promote to Warn status) was firing
with an illegal suggestion to write an anonymous lifetime in a
struct/item declaration (where we don't allow it). The linting code
was already deciding whether to act on the basis of a `ParamMode`
enum, indicating whether the present path-segment was part of an
expression, or anywhere else. The present case seemed to be part of
the "anywhere else", and yet meriting different rules as far as the
lint was concerned, so it seemed expedient to introduce a new enum
member. We yank out a `TyKind::Path` arm into its own method so that
we can call it with our new `ParamMode` specifically when lowering
struct fields. (The alternative strategy of changing the signature of
`lower_ty` to take a `ParamMode` would be inelegant given that most of
the `TyKind` match arm bodies therein don't concern themselves with
`ParamMode`.)

Resolves #61124.

5 years agoPatKind::Path: avoid calling resolve_ty_and_res_ufcs twice.
Mazdak Farrokhzad [Fri, 14 Jun 2019 07:00:21 +0000 (09:00 +0200)]
PatKind::Path: avoid calling resolve_ty_and_res_ufcs twice.

5 years agoAuto merge of #61803 - Centril:write_resolution, r=petrochenkov
bors [Fri, 14 Jun 2019 06:46:01 +0000 (06:46 +0000)]
Auto merge of #61803 - Centril:write_resolution, r=petrochenkov

typeck: small refactoring, add 'fn write_resolution'

5 years agoAuto merge of #61792 - lzutao:issue-51301, r=Centril
bors [Fri, 14 Jun 2019 03:57:28 +0000 (03:57 +0000)]
Auto merge of #61792 - lzutao:issue-51301, r=Centril

Add ui test for issue 51301

Closes #51301

5 years agoAdd explanation for E0592
Yuki Okushi [Fri, 14 Jun 2019 01:54:27 +0000 (10:54 +0900)]
Add explanation for E0592

5 years agoVerify that the clone method call actually corresponds to std::clone::Clone::clone
Esteban Küber [Fri, 14 Jun 2019 00:58:59 +0000 (17:58 -0700)]
Verify that the clone method call actually corresponds to std::clone::Clone::clone

5 years agoWhen suggesting to borrow, remove useless clones
Esteban Küber [Sat, 25 May 2019 01:24:20 +0000 (18:24 -0700)]
When suggesting to borrow, remove useless clones

5 years agotypeck: Fix ICE for blocks in repeat expr count.
David Wood [Thu, 13 Jun 2019 16:19:50 +0000 (17:19 +0100)]
typeck: Fix ICE for blocks in repeat expr count.

This commit extends the work in #61698 to get the `DefId` of const
parameters from block that resolve to a const parameter (as well as
const parameters directly, as it was previously).

5 years agoAuto merge of #61639 - Mark-Simulacrum:bootstrap-cleanup, r=alexcrichton
bors [Thu, 13 Jun 2019 22:23:42 +0000 (22:23 +0000)]
Auto merge of #61639 - Mark-Simulacrum:bootstrap-cleanup, r=alexcrichton

Bootstrap cleanup

Each commit is (mostly) standalone and probably best reviewed as such. Nothing too major just some drive-by nits as I was looking through the code.

r? @alexcrichton

5 years agoAdd a test for simple matches
Matthew Jasper [Sat, 25 May 2019 19:13:53 +0000 (20:13 +0100)]
Add a test for simple matches

5 years agoAdd some more comments on how TestKind works
Matthew Jasper [Sat, 25 May 2019 17:26:34 +0000 (18:26 +0100)]
Add some more comments on how TestKind works

5 years agoGenerate MIR thats easier for llvm for str matches
Matthew Jasper [Sat, 25 May 2019 16:11:27 +0000 (17:11 +0100)]
Generate MIR thats easier for llvm for str matches

LLVM appears to prefer (spend less time optimizing) long if chains if
it receives them in approzimately source order.
This fixes a ~10% regression for optimized builds of the encoding benchmark
on perf.rlo due to the changes to decision tree construction.

5 years agoCall str::eq and <[T]>::eq for match comparisons
Matthew Jasper [Sat, 25 May 2019 15:26:57 +0000 (16:26 +0100)]
Call str::eq and <[T]>::eq for match comparisons

We used to call the less efficient `<&str>::eq` and `<&[T]>::eq`.

5 years agoCreate fewer basic blocks in match MIR lowering
Matthew Jasper [Thu, 9 May 2019 22:01:39 +0000 (23:01 +0100)]
Create fewer basic blocks in match MIR lowering

5 years agoAuto merge of #61772 - alexcrichton:pr-and-master-builds, r=pietroalbini
bors [Thu, 13 Jun 2019 15:44:58 +0000 (15:44 +0000)]
Auto merge of #61772 - alexcrichton:pr-and-master-builds, r=pietroalbini

ci: Enable toolstate tracking on Azure

Currently just run it through its paces but don't actually push to
official locations. Instead let's just push to a separate fork (mine) as
well as open issues in a separate fork (mine). Make sure that people
aren't pinged for these issues as well!

This should hopefully ensure that everything is working on Azure and
give us a chance to work through any issues that come up.

Fixes https://github.com/rust-lang/rust/issues/61790
Fixes https://github.com/rust-lang/rust/issues/61371

5 years agoRemove unnecessary Std dependency
Mark Rousskov [Fri, 7 Jun 2019 16:05:42 +0000 (10:05 -0600)]
Remove unnecessary Std dependency

5 years agoDelete unused fields on Crate struct
Mark Rousskov [Fri, 7 Jun 2019 20:30:48 +0000 (14:30 -0600)]
Delete unused fields on Crate struct

5 years agoInline prepare_tool_cmd
Mark Rousskov [Fri, 7 Jun 2019 17:15:45 +0000 (11:15 -0600)]
Inline prepare_tool_cmd

Removing the tool argument in the previous commit means it's no longer
restricted to just bootstrap tools despite being written as such.
Inlining it prevents accidental use.

5 years agoDelete unnecessary command
Mark Rousskov [Fri, 7 Jun 2019 17:10:27 +0000 (11:10 -0600)]
Delete unnecessary command

5 years agoDelete Rustbook step
Mark Rousskov [Fri, 7 Jun 2019 15:39:28 +0000 (09:39 -0600)]
Delete Rustbook step

There's no need to have it given it merely forwarded to RustbookSrc.

5 years agotypeck: small refactoring, add 'fn write_resolution'
Mazdak Farrokhzad [Thu, 13 Jun 2019 14:44:50 +0000 (16:44 +0200)]
typeck: small refactoring, add 'fn write_resolution'

5 years agoci: Enable toolstate tracking on Azure
Alex Crichton [Wed, 12 Jun 2019 14:59:20 +0000 (07:59 -0700)]
ci: Enable toolstate tracking on Azure

Currently just run it through its paces but don't actually push to
official locations. Instead let's just push to a separate fork (mine) as
well as open issues in a separate fork (mine). Make sure that people
aren't pinged for these issues as well!

This should hopefully ensure that everything is working on Azure and
give us a chance to work through any issues that come up.

5 years agoAuto merge of #61799 - Centril:rollup-vpm5uxr, r=Centril
bors [Thu, 13 Jun 2019 12:52:29 +0000 (12:52 +0000)]
Auto merge of #61799 - Centril:rollup-vpm5uxr, r=Centril

Rollup of 5 pull requests

Successful merges:

 - #61598 (Handle index out of bound errors during const eval without panic)
 - #61720 (std: Remove internal definitions of `cfg_if!` macro)
 - #61757 (Deprecate ONCE_INIT in future 1.38 release)
 - #61766 (submodules: update clippy from c0dbd34b to bd33a97c)
 - #61791 (Small cleanup in `check_pat_path`)

Failed merges:

r? @ghost

5 years agoRollup merge of #61791 - Centril:cleanup-check_pat_path, r=petrochenkov
Mazdak Farrokhzad [Thu, 13 Jun 2019 12:52:00 +0000 (14:52 +0200)]
Rollup merge of #61791 - Centril:cleanup-check_pat_path, r=petrochenkov

Small cleanup in `check_pat_path`

5 years agoRollup merge of #61766 - matthiaskrgr:submodule_upd, r=oli-obk
Mazdak Farrokhzad [Thu, 13 Jun 2019 12:51:59 +0000 (14:51 +0200)]
Rollup merge of #61766 - matthiaskrgr:submodule_upd, r=oli-obk

submodules: update clippy from c0dbd34b to bd33a97c

Changes:
````
Fix implicit_return docs
rustup https://github.com/rust-lang/rust/pull/61758/files
Remove wrong lifetime from LintContext
Workaround for rust-lang/rustfmt#3615
Fixing eta with respect to lazy evaluation.
````
r? @oli-obk

5 years agoRollup merge of #61757 - sfackler:deprecate-once-init, r=alexcrichton
Mazdak Farrokhzad [Thu, 13 Jun 2019 12:51:57 +0000 (14:51 +0200)]
Rollup merge of #61757 - sfackler:deprecate-once-init, r=alexcrichton

Deprecate ONCE_INIT in future 1.38 release

Once::new() has been a stable const fn for a while now.

Closes #61746

5 years agoRollup merge of #61720 - alexcrichton:libstd-cfg-if-dep, r=sfackler
Mazdak Farrokhzad [Thu, 13 Jun 2019 12:51:56 +0000 (14:51 +0200)]
Rollup merge of #61720 - alexcrichton:libstd-cfg-if-dep, r=sfackler

std: Remove internal definitions of `cfg_if!` macro

This is duplicated in a few locations throughout the sysroot to work
around issues with not exporting a macro in libstd but still wanting it
available to sysroot crates to define blocks. Nowadays though we can
simply depend on the `cfg-if` crate on crates.io, allowing us to use it
from there!

5 years agoRollup merge of #61598 - estebank:const-idx, r=oli-obk
Mazdak Farrokhzad [Thu, 13 Jun 2019 12:51:53 +0000 (14:51 +0200)]
Rollup merge of #61598 - estebank:const-idx, r=oli-obk

Handle index out of bound errors during const eval without panic

Fix #61595

5 years agodocs: Use String in Rc::into_raw examples
Michal 'vorner' Vaner [Sat, 1 Jun 2019 09:55:25 +0000 (11:55 +0200)]
docs: Use String in Rc::into_raw examples

It is unclear if accessing an integer after `drop_in_place` has been
called on it is undefined behaviour or not, as demonstrated by the
discussion in
https://github.com/rust-lang/rust/pull/60766#pullrequestreview-243414222.

Avoid these uncertainties by using String which frees memory in its
`drop_in_place` to make sure this is undefined behaviour. The message in
the docs should be to watch out and not access the data after that, not
discussing when one maybe could get away with it O:-).

5 years agorevert change incorrectly identified as "hack"
Felix S Klock II [Thu, 13 Jun 2019 10:05:18 +0000 (12:05 +0200)]
revert change incorrectly identified as "hack"

put back negative impls to ensure `Span` is not `Send` nor `Sync`

5 years agoAuto merge of #61743 - RalfJung:miri, r=oli-obk
bors [Thu, 13 Jun 2019 08:28:15 +0000 (08:28 +0000)]
Auto merge of #61743 - RalfJung:miri, r=oli-obk

update miri

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

r? @oli-obk

5 years agoupdate miri
Ralf Jung [Thu, 13 Jun 2019 07:58:32 +0000 (09:58 +0200)]
update miri

5 years agosubmodules: update clippy from c0dbd34b to 7b2a7a22
Matthias Krüger [Thu, 13 Jun 2019 06:25:08 +0000 (08:25 +0200)]
submodules: update clippy from c0dbd34b to 7b2a7a22

Changes:
````
Fix wrong lifetime of TyCtxt
travis: Wait at most 30 minutes for base test
Typos and minor grammar corrections
Adds lint for integer division
redundant_closure_for_method_calls fixes: lint does not trigger when there is a difference in mutability lint does not trigger when the method belongs to a trait which is not implemebted directly (Deref)
Fix implicit_return docs
rustup https://github.com/rust-lang/rust/pull/61758/files
Remove wrong lifetime from LintContext
Workaround for rust-lang/rustfmt#3615
Fixing eta with respect to lazy evaluation.
````

5 years agoDeprecate ONCE_INIT
Steven Fackler [Wed, 12 Jun 2019 01:57:48 +0000 (18:57 -0700)]
Deprecate ONCE_INIT

Once::new() has been a stable const fn for a while now.

Closes #61746

5 years agoAuto merge of #61597 - lnicola:bump-rand, r=alexcrichton
bors [Thu, 13 Jun 2019 04:19:28 +0000 (04:19 +0000)]
Auto merge of #61597 - lnicola:bump-rand, r=alexcrichton

Bump dirs, rand and redox_users

Part of #57724.

5 years agoAdd ui test for issue 51301
Lzu Tao [Thu, 13 Jun 2019 03:03:28 +0000 (03:03 +0000)]
Add ui test for issue 51301

5 years agoSmall cleanup in check_pat_path.
Mazdak Farrokhzad [Thu, 13 Jun 2019 02:58:12 +0000 (04:58 +0200)]
Small cleanup in check_pat_path.

5 years agoAuto merge of #61789 - Centril:rollup-hhyvopq, r=Centril
bors [Thu, 13 Jun 2019 01:32:17 +0000 (01:32 +0000)]
Auto merge of #61789 - Centril:rollup-hhyvopq, r=Centril

Rollup of 9 pull requests

Successful merges:

 - #60376 (Stabilize Option::xor)
 - #61398 (Stabilize copy_within)
 - #61629 (Hygienize macros in the standard library)
 - #61675 (Include frame pointer for bare metal RISC-V targets)
 - #61750 (Fix x.py install)
 - #61761 (Add an alias for x86_64-sun-solaris target tuple)
 - #61762 (rustbuild: fix libtest_stamp)
 - #61763 (ci: fix ci stats upload condition)
 - #61776 (Fix typos in error_codes)

Failed merges:

r? @ghost

5 years agoRollup merge of #61776 - JohnTitor:fix-typo-in-error-codes, r=Centril
Mazdak Farrokhzad [Wed, 12 Jun 2019 23:49:37 +0000 (01:49 +0200)]
Rollup merge of #61776 - JohnTitor:fix-typo-in-error-codes, r=Centril

Fix typos in error_codes

`observedin` should be `observed in`.

5 years agoRollup merge of #61763 - pietroalbini:azure-fix-condition, r=alexcrichton
Mazdak Farrokhzad [Wed, 12 Jun 2019 23:49:35 +0000 (01:49 +0200)]
Rollup merge of #61763 - pietroalbini:azure-fix-condition, r=alexcrichton

ci: fix ci stats upload condition

The condition I suggested in #61632 was not correct and it errors out while evaluating. This fixes the condition. [Example of a failure](https://dev.azure.com/rust-lang/rust/_build/results?buildId=543).

r? @alexcrichton

5 years agoRollup merge of #61762 - Keruspe:rustbuild-libtest-fix, r=Mark-Simulacrum
Mazdak Farrokhzad [Wed, 12 Jun 2019 23:49:33 +0000 (01:49 +0200)]
Rollup merge of #61762 - Keruspe:rustbuild-libtest-fix, r=Mark-Simulacrum

rustbuild: fix libtest_stamp

Looks like an obvious copy/paste typo

5 years agoRollup merge of #61761 - lzutao:target-tuple-solaris, r=varkor
Mazdak Farrokhzad [Wed, 12 Jun 2019 23:49:32 +0000 (01:49 +0200)]
Rollup merge of #61761 - lzutao:target-tuple-solaris, r=varkor

Add an alias for x86_64-sun-solaris target tuple

Closes #40531

r? @varkor