]> git.lizzy.rs Git - rust.git/log
rust.git
4 years agocore: add IntoFuture trait and support for await
Sean McArthur [Thu, 26 Dec 2019 20:57:09 +0000 (12:57 -0800)]
core: add IntoFuture trait and support for await

4 years agoAuto merge of #67437 - matthew-healy:skip-llvm-rebuild, r=Mark-Simulacrum
bors [Fri, 27 Dec 2019 10:58:57 +0000 (10:58 +0000)]
Auto merge of #67437 - matthew-healy:skip-llvm-rebuild, r=Mark-Simulacrum

Add LLVM `skip-rebuild` option to `x.py`

This PR reimplements parts of @Walther's work from #65848, and closes #65612.

I decided not to implement the [arguments to override this setting](https://github.com/rust-lang/rust/issues/65612#issuecomment-544247546) in this PR. If there's strong feeling that this change shouldn't be merged without the overrides then I'm happy to close this until I've had a chance to add them in. Otherwise I'll aim to submit a second PR with those this weekend.

I'd have liked to have tested the change in `native.rs`, but there didn't seem to be any existing test infrastructure. I ran this a few times manually and it _worked on my machine_ though... ðŸ˜¬

4 years agoAuto merge of #67192 - oli-obk:const_zst_addr, r=RalfJung,varkor
bors [Fri, 27 Dec 2019 07:38:52 +0000 (07:38 +0000)]
Auto merge of #67192 - oli-obk:const_zst_addr, r=RalfJung,varkor

Various const eval and pattern matching ICE fixes

r? @RalfJung
cc @spastorino

This PR does not change existing behaviour anymore and just fixes a bunch of ICEs reachable from user code (sometimes even on stable via obscure union transmutes).

4 years agoAuto merge of #66936 - cjgillot:hirene-expr, r=Zoxc
bors [Fri, 27 Dec 2019 01:40:41 +0000 (01:40 +0000)]
Auto merge of #66936 - cjgillot:hirene-expr, r=Zoxc

Allocate HIR on an arena 2/4 -- Expr & Pat

This is the second PR in the series started by #66931

This time, commits don't really make sense on their own.
They are mostly split by type of compile error.

The additional diff is here: https://github.com/cjgillot/rust/compare/hirene-preamble...hirene-expr

4 years agoMove arena_vec inside lowering.
Camille GILLOT [Tue, 24 Dec 2019 17:57:28 +0000 (18:57 +0100)]
Move arena_vec inside lowering.

4 years agoRemove some type information.
Camille GILLOT [Tue, 3 Dec 2019 21:54:44 +0000 (22:54 +0100)]
Remove some type information.

4 years agoFewer calls to arena.alloc.
Camille GILLOT [Sun, 1 Dec 2019 20:10:43 +0000 (21:10 +0100)]
Fewer calls to arena.alloc.

4 years agoFallout in other crates.
Camille GILLOT [Sat, 30 Nov 2019 14:08:22 +0000 (15:08 +0100)]
Fallout in other crates.

4 years agoLowering for hir::Expr.
Camille GILLOT [Fri, 29 Nov 2019 18:01:31 +0000 (19:01 +0100)]
Lowering for hir::Expr.

4 years agoVisit for hir::Expr.
Camille GILLOT [Fri, 29 Nov 2019 13:08:03 +0000 (14:08 +0100)]
Visit for hir::Expr.

4 years agoSyntax for hir::Expr.
Camille GILLOT [Fri, 29 Nov 2019 12:43:03 +0000 (13:43 +0100)]
Syntax for hir::Expr.

4 years agoSkip LLVM rebuild when skip-rebuild is true
Matthew Healy [Thu, 19 Dec 2019 19:42:01 +0000 (20:42 +0100)]
Skip LLVM rebuild when skip-rebuild is true

4 years agoParse llvm_skip_rebuild into Config
Matthew Healy [Thu, 19 Dec 2019 18:55:42 +0000 (19:55 +0100)]
Parse llvm_skip_rebuild into Config

4 years agoDocument LLVM skip-rebuild config.toml option
Matthew Healy [Thu, 19 Dec 2019 18:46:19 +0000 (19:46 +0100)]
Document LLVM skip-rebuild config.toml option

4 years agoMake ui test bitwidth independent
Oliver Scherer [Tue, 24 Dec 2019 13:31:36 +0000 (14:31 +0100)]
Make ui test bitwidth independent

4 years agoFix rebase fallout
Oliver Scherer [Mon, 23 Dec 2019 16:13:50 +0000 (17:13 +0100)]
Fix rebase fallout

4 years agoUse the targetted const eval functions
Oliver Scherer [Mon, 23 Dec 2019 16:13:25 +0000 (17:13 +0100)]
Use the targetted const eval functions

4 years agoReintroduce the recursion comment
Oliver Scherer [Sun, 22 Dec 2019 20:31:24 +0000 (21:31 +0100)]
Reintroduce the recursion comment

4 years agoDocumentation nit
Oliver Scherer [Sun, 22 Dec 2019 20:28:25 +0000 (21:28 +0100)]
Documentation nit

4 years agoAdd a `const_eval` helper to `InterpCx`
Oliver Scherer [Sun, 22 Dec 2019 19:56:01 +0000 (20:56 +0100)]
Add a `const_eval` helper to `InterpCx`

4 years agoEarly abort instead of building up zero sized values
Oliver Scherer [Sun, 22 Dec 2019 19:39:35 +0000 (20:39 +0100)]
Early abort instead of building up zero sized values

4 years agoExplain why `const_eval` is ok here
Oliver Scherer [Sun, 22 Dec 2019 12:30:47 +0000 (13:30 +0100)]
Explain why `const_eval` is ok here

4 years agoTypo
Oliver Scherer [Sun, 22 Dec 2019 12:13:08 +0000 (13:13 +0100)]
Typo

4 years agoRemove unintended noisy log statement
Oliver Scherer [Sun, 22 Dec 2019 12:10:56 +0000 (13:10 +0100)]
Remove unintended noisy log statement

4 years agoExplain the currently necessary existance of `TransmuteSizeDiff`
Oliver Scherer [Sun, 22 Dec 2019 12:06:50 +0000 (13:06 +0100)]
Explain the currently necessary existance of `TransmuteSizeDiff`

4 years agoExplain what we are doing with parameter environments for statics
Oliver Scherer [Sun, 22 Dec 2019 11:59:15 +0000 (12:59 +0100)]
Explain what we are doing with parameter environments for statics

4 years agoComments should start capitalized and end in a period
Oliver Scherer [Sun, 22 Dec 2019 11:55:31 +0000 (12:55 +0100)]
Comments should start capitalized and end in a period

4 years agoExplain ParamEnv::reveal_all usage
Oliver Scherer [Sun, 22 Dec 2019 11:54:48 +0000 (12:54 +0100)]
Explain ParamEnv::reveal_all usage

4 years agoAdd regression test for ZST statics being allowed to "read" from themselves
Oliver Scherer [Fri, 20 Dec 2019 11:37:05 +0000 (12:37 +0100)]
Add regression test for ZST statics being allowed to "read" from themselves

4 years agoImmediately evaluate and validate constants when we want them as operands
Oliver Scherer [Fri, 20 Dec 2019 11:31:52 +0000 (12:31 +0100)]
Immediately evaluate and validate constants when we want them as operands

4 years agoInterning even happens when validation of a constant fails
Oliver Scherer [Sat, 14 Dec 2019 11:15:37 +0000 (12:15 +0100)]
Interning even happens when validation of a constant fails

4 years agoPrevent an ICE on invalid transmutes
Oliver Scherer [Fri, 13 Dec 2019 23:19:24 +0000 (00:19 +0100)]
Prevent an ICE on invalid transmutes

4 years agoComment on a few odd things that we should look at
Oliver Scherer [Fri, 13 Dec 2019 23:05:28 +0000 (00:05 +0100)]
Comment on a few odd things that we should look at

4 years agoSimplify `force_allocation_maybe_sized`
Oliver Scherer [Fri, 13 Dec 2019 23:05:04 +0000 (00:05 +0100)]
Simplify `force_allocation_maybe_sized`

4 years agoRetire `to_ptr` which should already have no users but still kept getting new ones
Oliver Scherer [Fri, 13 Dec 2019 23:04:27 +0000 (00:04 +0100)]
Retire `to_ptr` which should already have no users but still kept getting new ones

4 years agoDon't ICE on the use of integer addresses for ZST constants in pattern matching
Oliver Scherer [Fri, 13 Dec 2019 23:01:12 +0000 (00:01 +0100)]
Don't ICE on the use of integer addresses for ZST constants in pattern matching

4 years agoAuto merge of #67592 - matthewjasper:cleanup-match, r=Centril
bors [Thu, 26 Dec 2019 16:44:52 +0000 (16:44 +0000)]
Auto merge of #67592 - matthewjasper:cleanup-match, r=Centril

Prepare for lowering or-patterns

This is probably best reviewed commit-by-commit.

* Rustfmt `rustc_mir::build::{self, matches}`
* Remove `-Znll-dont-emit-read-for-match`
* Split `match_expr` into smaller functions
* Feature gate or-patterns in const contexts

cc https://github.com/rust-lang/rust/issues/54883

r? @Centril

4 years agoAuto merge of #67327 - oli-obk:cleanup, r=RalfJung
bors [Thu, 26 Dec 2019 13:15:05 +0000 (13:15 +0000)]
Auto merge of #67327 - oli-obk:cleanup, r=RalfJung

Split up `const_eval.rs`

Fixes #67316

r? @RalfJung

4 years agoRebase fallout
Oliver Scherer [Wed, 25 Dec 2019 00:28:30 +0000 (01:28 +0100)]
Rebase fallout

4 years agoA cycle error on a diverging function is now a const stack overflow again
Oliver Scherer [Mon, 23 Dec 2019 22:11:03 +0000 (23:11 +0100)]
A cycle error on a diverging function is now a const stack overflow again

4 years agoBail out before running the query
Oliver Scherer [Mon, 23 Dec 2019 16:33:09 +0000 (17:33 +0100)]
Bail out before running the query

4 years agoTidy
Oliver Scherer [Mon, 23 Dec 2019 16:31:55 +0000 (17:31 +0100)]
Tidy

4 years agoFix imports after rebase
Oliver Scherer [Mon, 23 Dec 2019 14:02:55 +0000 (15:02 +0100)]
Fix imports after rebase

4 years agoRename `query` module
Oliver Scherer [Mon, 23 Dec 2019 11:55:16 +0000 (12:55 +0100)]
Rename `query` module

4 years agoMove function definitions before their first use
Oliver Scherer [Sun, 22 Dec 2019 21:20:46 +0000 (22:20 +0100)]
Move function definitions before their first use

4 years agoMove all functions used by the queries to query.rs
Oliver Scherer [Wed, 25 Dec 2019 00:15:26 +0000 (01:15 +0100)]
Move all functions used by the queries to query.rs

4 years agoMove a function to make its adjacent impl block easier to discover
Oliver Scherer [Sun, 22 Dec 2019 20:10:43 +0000 (21:10 +0100)]
Move a function to make its adjacent impl block easier to discover

4 years agoMake some functions crate local
Oliver Scherer [Sun, 15 Dec 2019 16:50:37 +0000 (17:50 +0100)]
Make some functions crate local

4 years agoMove `eval_body_using_ecx` to the only module it is used in
Oliver Scherer [Wed, 25 Dec 2019 00:09:47 +0000 (01:09 +0100)]
Move `eval_body_using_ecx` to the only module it is used in

4 years agoMove `eval_const_fn_call` to the `const_eval` module
Oliver Scherer [Wed, 25 Dec 2019 00:08:39 +0000 (01:08 +0100)]
Move `eval_const_fn_call` to the `const_eval` module

4 years agoMove const eval query components into their own module
Oliver Scherer [Wed, 25 Dec 2019 00:06:51 +0000 (01:06 +0100)]
Move const eval query components into their own module

4 years agoMove const eval machine into its own module
Oliver Scherer [Wed, 25 Dec 2019 00:04:32 +0000 (01:04 +0100)]
Move const eval machine into its own module

4 years agoAuto merge of #66670 - crlf0710:normalize_ident, r=Dylan-DPC
bors [Thu, 26 Dec 2019 09:55:00 +0000 (09:55 +0000)]
Auto merge of #66670 - crlf0710:normalize_ident, r=Dylan-DPC

Normalize ident

Perform unicode normalization on identifiers. Resolving the first bullet point in #55467.

4 years agoAdd unicode-normalization to whitelist.
Charles Lew [Thu, 19 Dec 2019 03:57:30 +0000 (11:57 +0800)]
Add unicode-normalization to whitelist.

4 years agoAdd a test and bless existing test case.
Charles Lew [Sat, 23 Nov 2019 14:37:46 +0000 (22:37 +0800)]
Add a test and bless existing test case.

4 years agoNormalize identifiers in librustc_parse.
Charles Lew [Sat, 23 Nov 2019 14:33:40 +0000 (22:33 +0800)]
Normalize identifiers in librustc_parse.

4 years agoAuto merge of #67268 - estebank:assoc-types, r=oli-obk
bors [Thu, 26 Dec 2019 03:42:59 +0000 (03:42 +0000)]
Auto merge of #67268 - estebank:assoc-types, r=oli-obk

Tweak errors for missing associated types and type parameters

* On `dyn Trait` missing associated types, provide a structured suggestion for them
* On missing type parameters, provide structured suggestion for them
* Point at trait definition when missing required type parameter
* Tweak output of E0658
* Tweak wording of E0719
* Account for `Trait1 + Trait2` case

Fix #66380, fix #60595. CC #63711.

4 years agoAuto merge of #67580 - RalfJung:miri-unleash-tests, r=oli-obk
bors [Thu, 26 Dec 2019 00:27:13 +0000 (00:27 +0000)]
Auto merge of #67580 - RalfJung:miri-unleash-tests, r=oli-obk

test the unleashed Miri

In particular, test what happens when we try to drop something. Cc https://github.com/rust-lang/const-eval/issues/17

r? @oli-obk

4 years agoAuto merge of #66919 - dtolnay:description, r=KodrAus
bors [Wed, 25 Dec 2019 21:10:49 +0000 (21:10 +0000)]
Auto merge of #66919 - dtolnay:description, r=KodrAus

Deprecate Error::description for real

`description` has been documented as soft-deprecated since 1.27.0 (17 months ago). There is no longer any reason to call it or implement it.

This PR:

- adds `#[rustc_deprecated(since = "1.41.0")]` to `Error::description`;
- moves `description` (and `cause`, which is also deprecated) below the `source` and `backtrace` methods in the Error trait;
- reduces documentation of `description` and `cause` to take up much less vertical real estate in rustdocs, while preserving the example that shows how to render errors without needing to call `description`;
- removes the description function of all *currently unstable* Error impls in the standard library;
- marks `#[allow(deprecated)]` the description function of all *stable* Error impls in the standard library;
- replaces miscellaneous uses of `description` in example code and the compiler.

---

![description](https://user-images.githubusercontent.com/1940490/69910369-3bbaca80-13bf-11ea-94f7-2fe27a7ea333.png)

4 years agoFix rebase and sort assoc type list for deterministic output
Esteban Küber [Tue, 24 Dec 2019 22:10:55 +0000 (14:10 -0800)]
Fix rebase and sort assoc type list for deterministic output

4 years agoAuto merge of #67524 - LukasKalbertodt:improve-into-iter-lint, r=matthewjasper
bors [Wed, 25 Dec 2019 10:20:48 +0000 (10:20 +0000)]
Auto merge of #67524 - LukasKalbertodt:improve-into-iter-lint, r=matthewjasper

Generalize `array_into_iter` lint to also lint for boxed arrays

`Box` is special in that a method call on a box can move the value out
of the box. Thus, the same backwards-compatibility problem can arise
for boxed arrays as for simple arrays.

---

CC #66145
r? @matthewjasper  (as you reviewed the first PR)

4 years agouse error-pattern
Ralf Jung [Wed, 25 Dec 2019 10:18:39 +0000 (11:18 +0100)]
use error-pattern

4 years agoUse link in doc comment
matthewjasper [Tue, 24 Dec 2019 19:56:20 +0000 (19:56 +0000)]
Use link in doc comment

Co-Authored-By: Mazdak Farrokhzad <twingoow@gmail.com>
4 years agoFeature gate or patterns in const contexts
Matthew Jasper [Tue, 24 Dec 2019 16:43:17 +0000 (16:43 +0000)]
Feature gate or patterns in const contexts

4 years agoSplit `match_expr` into smaller functions
Matthew Jasper [Tue, 24 Dec 2019 16:35:11 +0000 (16:35 +0000)]
Split `match_expr` into smaller functions

4 years agoRemove `-Znll-dont-emit-read-for-match`
Matthew Jasper [Tue, 24 Dec 2019 14:31:03 +0000 (14:31 +0000)]
Remove `-Znll-dont-emit-read-for-match`

4 years agoReduce log level from info to debug
Matthew Jasper [Tue, 24 Dec 2019 14:20:12 +0000 (14:20 +0000)]
Reduce log level from info to debug

4 years agoDeprecate Error::description for real
David Tolnay [Sun, 1 Dec 2019 04:01:48 +0000 (20:01 -0800)]
Deprecate Error::description for real

`description` has been documented as soft-deprecated since 1.27.0 (17
months ago). There is no longer any reason to call it or implement it.

This commit:

- adds #[rustc_deprecated(since = "1.41.0")] to Error::description;

- moves description (and cause, which is also deprecated) below the
  source and backtrace methods in the Error trait;

- reduces documentation of description and cause to take up much less
  vertical real estate in rustdocs, while preserving the example that
  shows how to render errors without needing to call description;

- removes the description function of all *currently unstable* Error
  impls in the standard library;

- marks #[allow(deprecated)] the description function of all *stable*
  Error impls in the standard library;

- replaces miscellaneous uses of description in example code and the
  compiler.

4 years agoFix suggestion span for typo in associated type name
Esteban Küber [Thu, 19 Dec 2019 19:23:57 +0000 (11:23 -0800)]
Fix suggestion span for typo in associated type name

4 years agoCleanup: move code to their own methods and deduplicate actions
Esteban Küber [Wed, 18 Dec 2019 19:12:50 +0000 (11:12 -0800)]
Cleanup: move code to their own methods and deduplicate actions

4 years agoAccount for multiple trait bounds with missing associated types
Esteban Küber [Wed, 18 Dec 2019 02:15:06 +0000 (18:15 -0800)]
Account for multiple trait bounds with missing associated types

4 years agoAvoid output dependency on std spans
Esteban Küber [Fri, 13 Dec 2019 19:37:31 +0000 (11:37 -0800)]
Avoid output dependency on std spans

4 years agoUse structured suggestion for bad `Fn` traits
Esteban Küber [Fri, 13 Dec 2019 16:22:58 +0000 (08:22 -0800)]
Use structured suggestion for bad `Fn` traits

4 years agoHandle more specific case E0222
Esteban Küber [Fri, 13 Dec 2019 05:15:19 +0000 (21:15 -0800)]
Handle more specific case E0222

4 years agoreview comments: move error reporting to their own methods
Esteban Küber [Fri, 13 Dec 2019 01:26:19 +0000 (17:26 -0800)]
review comments: move error reporting to their own methods

4 years agoFix case in `associated-type-projection-from-multiple-supertraits.rs`
Esteban Küber [Thu, 12 Dec 2019 23:22:46 +0000 (15:22 -0800)]
Fix case in `associated-type-projection-from-multiple-supertraits.rs`

This still doesn't handle the case entirely correctly, requiring a more
targeted approach with a better suggestion, but at least now the
suggested syntax makes *some* sense.

4 years agoTweak errors for missing associated types and type parameters
Esteban Küber [Thu, 12 Dec 2019 22:48:46 +0000 (14:48 -0800)]
Tweak errors for missing associated types and type parameters

4 years agoAuto merge of #67303 - dtolnay:rls, r=Xanewok
bors [Wed, 25 Dec 2019 03:55:21 +0000 (03:55 +0000)]
Auto merge of #67303 - dtolnay:rls, r=Xanewok

Update rls submodule

This pulls in https://github.com/rust-lang/rls/pull/1603 in order to unblock https://github.com/rust-lang/rust/pull/66919.

r? @Xanewok

4 years agoAuto merge of #67596 - Mark-Simulacrum:tidy-silence-rustfmt, r=Centril
bors [Wed, 25 Dec 2019 00:41:55 +0000 (00:41 +0000)]
Auto merge of #67596 - Mark-Simulacrum:tidy-silence-rustfmt, r=Centril

(Mostly) finish formatting the repository

Silences tidy line length warnings on rustfmt-controlled files.

This leaves two things out of formatting: CloudABI (mostly because it's not really ours to control, it's upstream code that's mostly generated), and tests. The latter is a hard problem and maybe not one to worry too much about, we rarely edit old tests and reformatting them as we go if possible isn't too bad (they're generally small).

4 years agoFormat librustc_feature
Mark Rousskov [Tue, 24 Dec 2019 22:44:51 +0000 (17:44 -0500)]
Format librustc_feature

Use #[rustfmt::skip] on the tidy-parsed macro invocations

4 years agox.py fmt after previous deignore
Mark Rousskov [Tue, 24 Dec 2019 22:38:22 +0000 (17:38 -0500)]
x.py fmt after previous deignore

4 years agoSilence line length warnings
Mark Rousskov [Tue, 24 Dec 2019 21:21:26 +0000 (16:21 -0500)]
Silence line length warnings

rustfmt tries its best already, we should not fight with it.

4 years agoAuto merge of #67445 - llogiq:todo, r=dtolnay
bors [Tue, 24 Dec 2019 21:16:45 +0000 (21:16 +0000)]
Auto merge of #67445 - llogiq:todo, r=dtolnay

Differentiate todo! and unimplemented!

This updates the panic message and docs to make it clear that `todo!` is for unfinished code and `unimplemented!` is for partial trait or enum impls.

r? @Centril

4 years agoAuto merge of #67241 - mark-i-m:simplify-borrow_check-3, r=matthewjasper
bors [Tue, 24 Dec 2019 18:02:10 +0000 (18:02 +0000)]
Auto merge of #67241 - mark-i-m:simplify-borrow_check-3, r=matthewjasper

Refactorings to borrowck region diagnostic reporting

This PR is a followup to #66886 and #67404

EDIT: updated

In this PR:  Clean up how errors are collected from NLL: introduce `borrow_check::diagnostics::RegionErrors` to collect errors. This is later passed to `MirBorrowckCtx::report_region_errors` after the `MirBorrowckCtx` is created. This will allow us to refactor away some of the extra context structs floating around (but we don't do it in this PR).  `borrow_check::region_infer` is now mostly free of diagnostic generating code. The signatures of most of the functions in `region_infer` lose somewhere between 4 and 7 arguments :)

Left for future (feedback appreciated):

- Merge `ErrorRegionCtx` with `MirBorrowckCtx`, as suggested by @matthewjasper in https://github.com/rust-lang/rust/pull/66886#issuecomment-559949499
- Maybe move the contents of `borrow_check::nll` into `borrow_check` and remove the `nll` submodule altogether.
- Find a way to make `borrow_check::diagnostics::region_errors` less of a strange appendage to `RegionInferenceContext`. I'm not really sure how to do this yet. Ideas welcome.

4 years agoGeneralize `array_into_iter` lint to also lint for boxed arrays
Lukas Kalbertodt [Sun, 22 Dec 2019 13:26:28 +0000 (14:26 +0100)]
Generalize `array_into_iter` lint to also lint for boxed arrays

`Box` is special in that a method call on a box can move the value out
of the box. Thus, the same backwards-compatibility problem can arise
for boxed arrays as for simple arrays.

4 years agoAuto merge of #66221 - ohadravid:doc-constants, r=Dylan-DPC
bors [Tue, 24 Dec 2019 14:40:33 +0000 (14:40 +0000)]
Auto merge of #66221 - ohadravid:doc-constants, r=Dylan-DPC

Show the actual value of constant values in the documentation

Fixes #66099, making rustdoc show evaluated constant scalar values.

![image](https://user-images.githubusercontent.com/2358365/68474827-c7a95e80-0226-11ea-818a-ded7bbff861f.png)

where `main.rs` is
```
pub const VAL3: i32 = i32::max_value();
pub const VAL4: i32 = i32::max_value() - 1;
```

As a fallback, when a constant value is not evaluated (either because of an error or because it isn't a scalar), the original expression is used for consistency.

I mimicked the way min/max values of integers are [`pretty_print`ed](https://github.com/rust-lang/rust/blob/master/src/librustc/ty/print/pretty.rs#L900), to show both the value a the "hint". While a little goofy for `std`, in user crates I think it's actually rather helpful.

4 years agoDifferentiate todo! and unimplemented!
Andre Bogus [Fri, 20 Dec 2019 06:46:29 +0000 (07:46 +0100)]
Differentiate todo! and unimplemented!

4 years agoAuto merge of #67579 - RalfJung:miri, r=RalfJung
bors [Tue, 24 Dec 2019 11:38:45 +0000 (11:38 +0000)]
Auto merge of #67579 - RalfJung:miri, r=RalfJung

update miri

4 years agothis has sysroot spans to let's ignore it the usual way
Ralf Jung [Tue, 24 Dec 2019 11:28:24 +0000 (12:28 +0100)]
this has sysroot spans to let's ignore it the usual way

4 years agobetter variable names
Ralf Jung [Tue, 24 Dec 2019 11:24:32 +0000 (12:24 +0100)]
better variable names

4 years agoadd test for dropping in const
Ralf Jung [Tue, 24 Dec 2019 11:20:36 +0000 (12:20 +0100)]
add test for dropping in const

4 years agobootstrap miri: remove no longer used env var
Ralf Jung [Tue, 24 Dec 2019 10:54:25 +0000 (11:54 +0100)]
bootstrap miri: remove no longer used env var

4 years agoupdate miri
Ralf Jung [Tue, 24 Dec 2019 10:51:40 +0000 (11:51 +0100)]
update miri

4 years agoShow value for consts in the documentation
Ohad Ravid [Wed, 11 Dec 2019 13:50:19 +0000 (14:50 +0100)]
Show value for consts in the documentation

4 years agoAuto merge of #67575 - Centril:rollup-feikoir, r=Centril
bors [Tue, 24 Dec 2019 03:40:33 +0000 (03:40 +0000)]
Auto merge of #67575 - Centril:rollup-feikoir, r=Centril

Rollup of 7 pull requests

Successful merges:

 - #67337 (Ensure that evaluating or validating a constant never reads from a static)
 - #67543 (Add regression tests for fixed ICEs)
 - #67547 (Cleanup err codes)
 - #67551 (Add long error code explanation message for E0627)
 - #67561 (remove `description` from `Error` impls in docs)
 - #67569 (Clean up unsafety in char::encode_utf8)
 - #67572 (Use the chocolatey CDN directly to avoid the flaky API)

Failed merges:

r? @ghost

4 years agoRollup merge of #67572 - aidanhs:aphs-choco-direct-cdn, r=Mark-Simulacrum
Mazdak Farrokhzad [Tue, 24 Dec 2019 03:40:03 +0000 (04:40 +0100)]
Rollup merge of #67572 - aidanhs:aphs-choco-direct-cdn, r=Mark-Simulacrum

Use the chocolatey CDN directly to avoid the flaky API

4 years agoRollup merge of #67569 - Mark-Simulacrum:opt-char-encode, r=oli-obk
Mazdak Farrokhzad [Tue, 24 Dec 2019 03:40:02 +0000 (04:40 +0100)]
Rollup merge of #67569 - Mark-Simulacrum:opt-char-encode, r=oli-obk

Clean up unsafety in char::encode_utf8

This originally started as an attempt to allow LLVM to optimize through
encode_utf8 to detect the try_encode_utf8 case (#52579, #52580), but due to a
typo my conclusion that my optimizations were successful was incorrect.

Furthermore, as far as I can tell, this optimization is probably just not
possible with LLVM today.  This [code](https://rust.godbolt.org/z/JggRj4)
compiles down to a long series of compares, notably, two identical series of
compares. That essentially means that LLVM is today unable to see that these two
ifs are identical and as such can be merged and then realize that no value of
the if condition can result in a call to `please_delete`. As such, for now, we
do not attempt to specifically optimize for that case.

4 years agoRollup merge of #67561 - euclio:remove-description, r=jonas-schievink
Mazdak Farrokhzad [Tue, 24 Dec 2019 03:40:00 +0000 (04:40 +0100)]
Rollup merge of #67561 - euclio:remove-description, r=jonas-schievink

remove `description` from `Error` impls in docs

Since `description` is soft-deprecated, there's no need to show it implemented in these examples.

4 years agoRollup merge of #67551 - ldm0:E0627, r=Dylan-DPC
Mazdak Farrokhzad [Tue, 24 Dec 2019 03:39:58 +0000 (04:39 +0100)]
Rollup merge of #67551 - ldm0:E0627, r=Dylan-DPC

Add long error code explanation message for E0627

Part of #61137.

r? @GuillaumeGomez

4 years agoRollup merge of #67547 - GuillaumeGomez:cleanup-err-codes, r=Dylan-DPC
Mazdak Farrokhzad [Tue, 24 Dec 2019 03:39:57 +0000 (04:39 +0100)]
Rollup merge of #67547 - GuillaumeGomez:cleanup-err-codes, r=Dylan-DPC

Cleanup err codes

r? @Dylan-DPC