]> git.lizzy.rs Git - rust.git/log
rust.git
4 years agouse `require_lang_item` over `unwrap`.
Bastian Kauschke [Wed, 13 May 2020 12:46:15 +0000 (14:46 +0200)]
use `require_lang_item` over `unwrap`.

4 years agoClean up E0582 explanation
Guillaume Gomez [Wed, 13 May 2020 11:40:55 +0000 (13:40 +0200)]
Clean up E0582 explanation

4 years agoReplace some usages of the old `unescape_` functions in AST, clippy and tests.
Julian Wollersberger [Wed, 13 May 2020 08:03:49 +0000 (10:03 +0200)]
Replace some usages of the old `unescape_` functions in AST, clippy and tests.

4 years agoUnified `validate_{byte,str,raw_str,raw_byte_str}_escape` methods into one method...
Julian Wollersberger [Wed, 13 May 2020 07:52:01 +0000 (09:52 +0200)]
Unified `validate_{byte,str,raw_str,raw_byte_str}_escape` methods into one method `validate_literal_escape` with a mode argument.
This enables simplifying the `match` in `cook_lexer_literal()`
and it eliminates 90 lines of repetition :)

4 years agoUnified `unescape_{char,byte,str,byte_str,raw_str,raw_byte_str}` methods into one...
Julian Wollersberger [Wed, 13 May 2020 07:42:30 +0000 (09:42 +0200)]
Unified `unescape_{char,byte,str,byte_str,raw_str,raw_byte_str}` methods into one method `unescape_literal` with a mode argument.

4 years agoAuto merge of #71451 - estebank:suggest-super-trait-constraint, r=nikomatsakis
bors [Wed, 13 May 2020 06:54:15 +0000 (06:54 +0000)]
Auto merge of #71451 - estebank:suggest-super-trait-constraint, r=nikomatsakis

Suggest adding super trait constraints

4 years agoChange `Iterator::nth` to use `self.next()` in a `while` loop.
Nicholas Nethercote [Wed, 13 May 2020 05:48:08 +0000 (15:48 +1000)]
Change `Iterator::nth` to use `self.next()` in a `while` loop.

Currently it uses `for x in self`, which seems dubious within an
iterator method. Furthermore, `self.next()` is used in all the other
iterator methods.

4 years agoUse simpler impls for some `Iterator` methods for slices.
Nicholas Nethercote [Wed, 13 May 2020 05:47:19 +0000 (15:47 +1000)]
Use simpler impls for some `Iterator` methods for slices.

The default implementations of several `Iterator` methods use `fold` or
`try_fold`, which works, but is overkill for slices and bloats the
amount of LLVM IR generated and consequently hurts compile times.

This commit adds the simple, obvious implementations for `for_each`,
`all`, `any`, `find`, `find_map`, and simplifies the existing
implementations for `position` and `rposition`. These changes reduce
compile times significantly on some benchmarks.

4 years agoAuto merge of #70416 - mzohreva:mz/sgx-test, r=nikomatsakis
bors [Wed, 13 May 2020 03:29:00 +0000 (03:29 +0000)]
Auto merge of #70416 - mzohreva:mz/sgx-test, r=nikomatsakis

Process termination test for SGX

The issue is described in https://github.com/fortanix/rust-sgx/issues/109

cc @jethrogb

4 years agoBe less aggressive with `DroplessArena`/`TypedArena` growth.
Nicholas Nethercote [Mon, 4 May 2020 09:25:09 +0000 (19:25 +1000)]
Be less aggressive with `DroplessArena`/`TypedArena` growth.

`DroplessArena` and `TypedArena` use an aggressive growth strategy: the
first chunk is 4 KiB, the second is 8 KiB, and it keeps on doubling
indefinitely. DHAT profiles show that sometimes this results in large
chunks (e.g. 16-128 MiB) that are barely filled. Although these don't
contribute to RSS, they clog up the DHAT profiles.

This commit changes things so that the doubling stops at 2 MiB. This is
large enough that chunk allocations are still rare (you might get 100s
instead of 10s of them) but avoids lots of unused space in the worst
case. It gives a slight speed-up to cycle counts in some cases.

4 years agoFix the new capacity measurement in arenas.
Nicholas Nethercote [Mon, 4 May 2020 07:17:07 +0000 (17:17 +1000)]
Fix the new capacity measurement in arenas.

For the given code paths, the amount of space used in the previous chunk
is irrelevant.

(This will almost never make a difference to behaviour, but it makes the
code clearer.)

4 years agoadd long error explanation for E0228
Jade McGough [Tue, 12 May 2020 00:28:24 +0000 (17:28 -0700)]
add long error explanation for E0228

4 years agoreview comments
Esteban Küber [Tue, 12 May 2020 18:56:11 +0000 (11:56 -0700)]
review comments

4 years agoUpdate books
Eric Huss [Tue, 12 May 2020 18:27:03 +0000 (11:27 -0700)]
Update books

4 years agofix test output after rebase
Esteban Küber [Thu, 7 May 2020 19:54:05 +0000 (12:54 -0700)]
fix test output after rebase

4 years agoIncrease verbosity of bound restriction suggestions
Esteban Küber [Wed, 22 Apr 2020 23:31:58 +0000 (16:31 -0700)]
Increase verbosity of bound restriction suggestions

- Make the bound restriction suggestion `span_suggestion_verbose`.
- Fix whitespace typo.

4 years agoSuggest adding super trait constraints
Esteban Küber [Wed, 22 Apr 2020 23:03:39 +0000 (16:03 -0700)]
Suggest adding super trait constraints

4 years agoProvide separate option for std debug asserts
Mark Rousskov [Tue, 12 May 2020 17:00:10 +0000 (13:00 -0400)]
Provide separate option for std debug asserts

4 years agoMap to -> return.
Laurence Tratt [Tue, 12 May 2020 15:54:29 +0000 (16:54 +0100)]
Map to -> return.

4 years agoWarn against thread::sleep in async fn
Kornel [Tue, 12 May 2020 15:38:02 +0000 (16:38 +0100)]
Warn against thread::sleep in async fn

4 years agoFix bootstrap failing on win32
Joshua Cotton [Thu, 7 May 2020 00:24:40 +0000 (20:24 -0400)]
Fix bootstrap failing on win32

4 years agoAuto merge of #72091 - RalfJung:miri, r=RalfJung
bors [Tue, 12 May 2020 13:59:16 +0000 (13:59 +0000)]
Auto merge of #72091 - RalfJung:miri, r=RalfJung

update miri

Fixes https://github.com/rust-lang/rust/issues/72037
Cc @rust-lang/miri r? @ghost

4 years agoAdd doc comment for `rustc_middle::mir::mono::Linkage`
Wesley Wiser [Tue, 12 May 2020 12:11:58 +0000 (08:11 -0400)]
Add doc comment for `rustc_middle::mir::mono::Linkage`

4 years agoClean up E0581 explanation
Guillaume Gomez [Tue, 12 May 2020 11:36:57 +0000 (13:36 +0200)]
Clean up E0581 explanation

4 years agoPointer printing: do not print 0 offset
Ralf Jung [Fri, 1 May 2020 10:10:06 +0000 (12:10 +0200)]
Pointer printing: do not print 0 offset

4 years agoAuto merge of #72134 - Dylan-DPC:rollup-h3shfz5, r=Dylan-DPC
bors [Tue, 12 May 2020 10:28:08 +0000 (10:28 +0000)]
Auto merge of #72134 - Dylan-DPC:rollup-h3shfz5, r=Dylan-DPC

Rollup of 5 pull requests

Successful merges:

 - #71737 (Miri: run liballoc tests with threads)
 - #71928 (Add strikethrough support to rustdoc)
 - #72048 (Visit move out of `_0` when visiting `return`)
 - #72096 (Make MIR typeck use `LocalDefId` and fix docs)
 - #72128 (strings do not have to be valid UTF-8 any more)

Failed merges:

r? @ghost

4 years agoRollup merge of #72128 - RalfJung:str-validity, r=oli-obk
Dylan DPC [Tue, 12 May 2020 09:41:15 +0000 (11:41 +0200)]
Rollup merge of #72128 - RalfJung:str-validity, r=oli-obk

strings do not have to be valid UTF-8 any more

Cc https://github.com/rust-lang/reference/pull/792
r? @oli-obk

4 years agoRollup merge of #72096 - jonas-schievink:mirck-docs, r=matthewjasper
Dylan DPC [Tue, 12 May 2020 09:41:13 +0000 (11:41 +0200)]
Rollup merge of #72096 - jonas-schievink:mirck-docs, r=matthewjasper

Make MIR typeck use `LocalDefId` and fix docs

The docs on `fn type_check` were not in sync with the arguments it takes.

r? @matthewjasper

4 years agoRollup merge of #72048 - jonas-schievink:visit-return, r=oli-obk
Dylan DPC [Tue, 12 May 2020 09:41:12 +0000 (11:41 +0200)]
Rollup merge of #72048 - jonas-schievink:visit-return, r=oli-obk

Visit move out of `_0` when visiting `return`

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

4 years agoRollup merge of #71928 - mibac138:strikethrough, r=GuillaumeGomez
Dylan DPC [Tue, 12 May 2020 09:41:10 +0000 (11:41 +0200)]
Rollup merge of #71928 - mibac138:strikethrough, r=GuillaumeGomez

Add strikethrough support to rustdoc

Implements uncontroversial part of #71183.
r? @GuillaumeGomez

4 years agoRollup merge of #71737 - RalfJung:miri-test-threads, r=shepmaster
Dylan DPC [Tue, 12 May 2020 09:41:05 +0000 (11:41 +0200)]
Rollup merge of #71737 - RalfJung:miri-test-threads, r=shepmaster

Miri: run liballoc tests with threads

Miri now supports threads, so we can run these tests. :)

4 years agoChange `WorkProduct::saved_files` to an `Option`.
Nicholas Nethercote [Tue, 12 May 2020 05:56:02 +0000 (15:56 +1000)]
Change `WorkProduct::saved_files` to an `Option`.

Because there is at most one file.

4 years agostrings do not have to be valid UTF-8 any more
Ralf Jung [Tue, 12 May 2020 07:46:41 +0000 (09:46 +0200)]
strings do not have to be valid UTF-8 any more

4 years agoRemove ty::UnnormalizedProjection
Jack Huey [Tue, 12 May 2020 05:56:29 +0000 (01:56 -0400)]
Remove ty::UnnormalizedProjection

4 years agoSplit `RawVec::grow` up.
Nicholas Nethercote [Mon, 11 May 2020 03:17:28 +0000 (13:17 +1000)]
Split `RawVec::grow` up.

The amortized case is much more common than the exact case, and it is
typically instantiated many times.

Also, we can put a chunk of the code into a function that isn't generic
over T, which reduces the amount of LLVM IR generated quite a lot,
improving compile times.

4 years agoRemove `RawVec::double`.
Nicholas Nethercote [Mon, 11 May 2020 02:26:59 +0000 (12:26 +1000)]
Remove `RawVec::double`.

It's only used once, for `VecDeque`, and can easily be replaced by
something else. The commit changes `grow_if_necessary` to `grow` to
avoid some small regressions caused by changed inlining.

The commit also removes `Strategy::Double`, and streamlines the
remaining variants of `Strategy`.

It's a compile time win on some benchmarks because the many
instantations of `RawVec::grow` are a little smaller.

4 years agoModify SimplifyArmIdentity so it can trigger on mir-opt-level=1
Wesley Wiser [Tue, 12 May 2020 00:13:15 +0000 (20:13 -0400)]
Modify SimplifyArmIdentity so it can trigger on mir-opt-level=1

I also added test cases to make sure the optimization can fire on all of
these cases:

```rust
fn case_1(o: Option<u8>) -> Option<u8> {
  match o {
    Some(u) => Some(u),
    None => None,
  }
}

fn case2(r: Result<u8, i32>) -> Result<u8, i32> {
  match r {
    Ok(u) => Ok(u),
    Err(i) => Err(i),
  }
}

fn case3(r: Result<u8, i32>) -> Result<u8, i32> {
  let u = r?;
  Ok(u)
}

```

Without MIR inlining, this still does not completely optimize away the
`?` operator because the `Try::into_result()`, `From::from()` and
`Try::from_error()` calls still exist. This does move us a bit closer to
that goal though because:

- We can now run the pass on mir-opt-level=1

- We no longer depend on the copy propagation pass running which is
  unlikely to stabilize anytime soon.

4 years agoAuto merge of #72120 - Dylan-DPC:rollup-ca0tur2, r=Dylan-DPC
bors [Mon, 11 May 2020 23:14:06 +0000 (23:14 +0000)]
Auto merge of #72120 - Dylan-DPC:rollup-ca0tur2, r=Dylan-DPC

Rollup of 10 pull requests

Successful merges:

 - #72014 (Deprecated emoji)
 - #72019 (Fix debug assertion in error code)
 - #72027 (Use CDN for ci-caches on download)
 - #72044 (use min_specialization for some rustc crates where it requires no changes)
 - #72052 (display `ConstKind::Param`)
 - #72067 (Emit a warning when optimization fuel runs out)
 - #72072 (doc: minus (U+2212) instead of dash (U+002D) for negative infinity)
 - #72077 (Improve E0571 wording)
 - #72107 (Clean up E0579 explanation)
 - #72109 (Fix clippy warnings)

Failed merges:

r? @ghost

4 years agoRemove `RawVec::double_in_place`.
Nicholas Nethercote [Mon, 11 May 2020 01:46:13 +0000 (11:46 +1000)]
Remove `RawVec::double_in_place`.

It's unused.

4 years agoRollup merge of #72109 - matthiaskrgr:cl8ppy, r=Dylan-DPC
Dylan DPC [Mon, 11 May 2020 20:21:08 +0000 (22:21 +0200)]
Rollup merge of #72109 - matthiaskrgr:cl8ppy, r=Dylan-DPC

Fix clippy warnings

Fixes clippy::{cone_on_copy, filter_next, redundant_closure, single_char_pattern, len_zero,redundant_field_names, useless_format, identity_conversion, map_clone, into_iter_on_ref, needless_return, option_as_ref_deref, unused_unit, unnecessary_mut_passed}

r? @Dylan-DPC

4 years agoRollup merge of #72107 - GuillaumeGomez:cleanup-e0579, r=Dylan-DPC
Dylan DPC [Mon, 11 May 2020 20:21:07 +0000 (22:21 +0200)]
Rollup merge of #72107 - GuillaumeGomez:cleanup-e0579, r=Dylan-DPC

Clean up E0579 explanation

r? @Dylan-DPC

4 years agoRollup merge of #72077 - GuillaumeGomez:cleanup-E0571, r=Dylan-DPC
Dylan DPC [Mon, 11 May 2020 20:21:05 +0000 (22:21 +0200)]
Rollup merge of #72077 - GuillaumeGomez:cleanup-E0571, r=Dylan-DPC

Improve E0571 wording

r? @Dylan-DPC

4 years agoRollup merge of #72072 - tspiteri:minus-inf, r=Dylan-DPC
Dylan DPC [Mon, 11 May 2020 20:21:03 +0000 (22:21 +0200)]
Rollup merge of #72072 - tspiteri:minus-inf, r=Dylan-DPC

doc: minus (U+2212) instead of dash (U+002D) for negative infinity

Like #67430, for the new associated constants.

4 years agoRollup merge of #72067 - jonas-schievink:fuel-warn, r=varkor
Dylan DPC [Mon, 11 May 2020 20:21:01 +0000 (22:21 +0200)]
Rollup merge of #72067 - jonas-schievink:fuel-warn, r=varkor

Emit a warning when optimization fuel runs out

`eprintln!` gets swallowed by Cargo too easily.

4 years agoRollup merge of #72052 - lcnr:const_pprint, r=ecstatic-morse
Dylan DPC [Mon, 11 May 2020 20:20:59 +0000 (22:20 +0200)]
Rollup merge of #72052 - lcnr:const_pprint, r=ecstatic-morse

display `ConstKind::Param`

4 years agoRollup merge of #72044 - RalfJung:min-spec, r=matthewjasper
Dylan DPC [Mon, 11 May 2020 20:20:57 +0000 (22:20 +0200)]
Rollup merge of #72044 - RalfJung:min-spec, r=matthewjasper

use min_specialization for some rustc crates where it requires no changes

and add FIXME for the rest

Cc @matthewjasper

4 years agoRollup merge of #72027 - Mark-Simulacrum:ci-caches, r=pietroalbini
Dylan DPC [Mon, 11 May 2020 20:20:55 +0000 (22:20 +0200)]
Rollup merge of #72027 - Mark-Simulacrum:ci-caches, r=pietroalbini

Use CDN for ci-caches on download

This will reduce costs, as well as lays the groundwork for developers to be able
to locally pull the published docker images without needing AWS credentials.

r? @pietroalbini

4 years agoRollup merge of #72019 - matthewjasper:dont-skip-binder, r=davidtwco
Dylan DPC [Mon, 11 May 2020 20:20:54 +0000 (22:20 +0200)]
Rollup merge of #72019 - matthewjasper:dont-skip-binder, r=davidtwco

Fix debug assertion in error code

Closes #70813

4 years agoRollup merge of #72014 - GuillaumeGomez:deprecated-emoji, r=kinnison,ollie27
Dylan DPC [Mon, 11 May 2020 20:20:51 +0000 (22:20 +0200)]
Rollup merge of #72014 - GuillaumeGomez:deprecated-emoji, r=kinnison,ollie27

Deprecated emoji

Fixes #67872.

r? @kinnison

cc @rust-lang/rustdoc

4 years agoFix hang in lexical_region_resolve
Matthew Jasper [Sun, 10 May 2020 20:09:56 +0000 (21:09 +0100)]
Fix hang in lexical_region_resolve

4 years agoUpdate Cargo.lock
flip1995 [Mon, 11 May 2020 19:18:42 +0000 (21:18 +0200)]
Update Cargo.lock

4 years agoMerge commit '43a1777b89cf6791f9e20878b4e5e3ae907867a5' into clippyup
flip1995 [Mon, 11 May 2020 18:23:47 +0000 (20:23 +0200)]
Merge commit '43a1777b89cf6791f9e20878b4e5e3ae907867a5' into clippyup

4 years agoAuto merge of #72089 - Mark-Simulacrum:error-is-really-an-error, r=pietroalbini
bors [Mon, 11 May 2020 16:33:26 +0000 (16:33 +0000)]
Auto merge of #72089 - Mark-Simulacrum:error-is-really-an-error, r=pietroalbini

Fail if I/O error occurs during testing

First known case of this is in https://github.com/rust-lang/rust/pull/72053#issuecomment-626364402 but may have happened before then.

r? @pietroalbini

4 years agoFix clippy warnings
Matthias Krüger [Mon, 11 May 2020 11:01:37 +0000 (13:01 +0200)]
Fix clippy warnings

Fixes clippy::{cone_on_copy, filter_next, redundant_closure, single_char_pattern, len_zero,redundant_field_names, useless_format, identity_conversion, map_clone, into_iter_on_ref, needless_return, option_as_ref_deref, unused_unit, unnecessary_mut_passed}

4 years agoConfigure cache domain for GHA
Mark Rousskov [Mon, 11 May 2020 14:50:53 +0000 (10:50 -0400)]
Configure cache domain for GHA

4 years agofix test_weak_count_locked for Miri
Ralf Jung [Sun, 3 May 2020 10:34:53 +0000 (12:34 +0200)]
fix test_weak_count_locked for Miri

4 years agorustbook: Bump mdbook dependency
Igor Matuszewski [Tue, 5 May 2020 12:05:06 +0000 (14:05 +0200)]
rustbook: Bump mdbook dependency

4 years agocargo update -p derive-new
Igor Matuszewski [Tue, 5 May 2020 11:30:49 +0000 (13:30 +0200)]
cargo update -p derive-new

4 years agocargo update -p pest_generator
Igor Matuszewski [Tue, 5 May 2020 11:26:29 +0000 (13:26 +0200)]
cargo update -p pest_generator

4 years agocargo update -p failure_derive
Igor Matuszewski [Tue, 5 May 2020 11:26:16 +0000 (13:26 +0200)]
cargo update -p failure_derive

4 years agocargo update -p serde_derive
Igor Matuszewski [Tue, 5 May 2020 11:26:02 +0000 (13:26 +0200)]
cargo update -p serde_derive

4 years agoClean up E0579 explanation
Guillaume Gomez [Mon, 11 May 2020 11:22:56 +0000 (13:22 +0200)]
Clean up E0579 explanation

4 years agoupdate miri some more
Ralf Jung [Mon, 11 May 2020 10:13:53 +0000 (12:13 +0200)]
update miri some more

4 years agoAuto merge of #71953 - oli-obk:const_prop_deaggregates, r=wesleywiser
bors [Mon, 11 May 2020 07:23:31 +0000 (07:23 +0000)]
Auto merge of #71953 - oli-obk:const_prop_deaggregates, r=wesleywiser

Const prop aggregates even if partially or fully modified

r? @wesleywiser

cc @rust-lang/wg-mir-opt I'm moderately scared of this change, but I'm confident in having reviewed all the cases.

4 years agobless ui tests
csmoe [Sun, 10 May 2020 14:34:20 +0000 (22:34 +0800)]
bless ui tests

4 years agoMake MIR typeck use `LocalDefId` and fix docs
Jonas Schievink [Mon, 11 May 2020 00:10:25 +0000 (02:10 +0200)]
Make MIR typeck use `LocalDefId` and fix docs

4 years agocmdline: Make target features individually overridable
Vadim Petrochenkov [Sun, 10 May 2020 21:16:16 +0000 (00:16 +0300)]
cmdline: Make target features individually overridable

4 years agorustc_driver::main: more informative return type
Ralf Jung [Sun, 10 May 2020 22:11:42 +0000 (00:11 +0200)]
rustc_driver::main: more informative return type

4 years agoupdate miri
Ralf Jung [Sun, 10 May 2020 21:55:41 +0000 (23:55 +0200)]
update miri

4 years agoRun rustfmt
Marko Mijalkovic [Sun, 10 May 2020 21:53:04 +0000 (17:53 -0400)]
Run rustfmt

4 years agoRenamed lld_link_script to link_script and support all GNU-like linkers
Marko Mijalkovic [Sun, 10 May 2020 21:39:57 +0000 (17:39 -0400)]
Renamed lld_link_script to link_script and support all GNU-like linkers

4 years agorustc_driver: factor out computing the exit code
Ralf Jung [Sun, 10 May 2020 21:36:41 +0000 (23:36 +0200)]
rustc_driver: factor out computing the exit code

4 years agoFail if I/O error occurs during testing
Mark Rousskov [Sun, 10 May 2020 20:53:48 +0000 (16:53 -0400)]
Fail if I/O error occurs during testing

4 years agoAuto merge of #71825 - contrun:cg-option-strip, r=petrochenkov
bors [Sun, 10 May 2020 20:48:40 +0000 (20:48 +0000)]
Auto merge of #71825 - contrun:cg-option-strip, r=petrochenkov

add codegen option strip

closes https://github.com/rust-lang/rust/issues/71757

I don't know if the flags added here works for all linkers. I only tested on my Linux pc. I also don't know what is the best for emlinker, PtxLinker, MsvcLinker. The option for WasmLd is copied from https://aransentin.github.io/cwasm/.

4 years agoremove lldb package from bootstrap, config and build-manifest
Ralf Jung [Sat, 9 May 2020 17:53:48 +0000 (19:53 +0200)]
remove lldb package from bootstrap, config and build-manifest

it's not been built since a long time ago

4 years agoAdd lld_link_script to TargetOptions
Marko Mijalkovic [Sun, 10 May 2020 20:06:33 +0000 (16:06 -0400)]
Add lld_link_script to TargetOptions

4 years agoremove try_trait lang item
csmoe [Sun, 10 May 2020 14:34:01 +0000 (22:34 +0800)]
remove try_trait lang item

4 years agosuggest await before try when performing trait selection
csmoe [Sun, 10 May 2020 12:07:42 +0000 (20:07 +0800)]
suggest await before try when performing trait selection

4 years agonormalize Future::Ouput
csmoe [Sat, 9 May 2020 14:04:02 +0000 (22:04 +0800)]
normalize Future::Ouput

4 years agoadd try trait as lang item
csmoe [Wed, 6 May 2020 10:44:14 +0000 (18:44 +0800)]
add try trait as lang item

4 years agoadd test case for issue-61076
csmoe [Wed, 6 May 2020 10:43:56 +0000 (18:43 +0800)]
add test case for issue-61076

4 years agoEmit a warning when optimization fuel runs out
Jonas Schievink [Sat, 9 May 2020 22:33:08 +0000 (00:33 +0200)]
Emit a warning when optimization fuel runs out

`eprintln!` gets swallowed by Cargo too easily.

4 years agoAuto merge of #72074 - RalfJung:rollup-1ns58no, r=RalfJung
bors [Sun, 10 May 2020 12:07:34 +0000 (12:07 +0000)]
Auto merge of #72074 - RalfJung:rollup-1ns58no, r=RalfJung

Rollup of 4 pull requests

Successful merges:

 - #71840 (Rework MIR drop tree lowering)
 - #71882 (Update the `cc` crate)
 - #71945 (Sort "implementations on foreign types" section in the sidebar)
 - #72043 (Add missing backtick in E0569 explanation)

Failed merges:

r? @ghost

4 years agoImprove E0571 wording
Guillaume Gomez [Sun, 10 May 2020 10:40:11 +0000 (12:40 +0200)]
Improve E0571 wording

4 years agoupdate stacker to 0.1.9 to unbreak build on OpenBSD
Sébastien Marie [Sun, 10 May 2020 10:23:13 +0000 (10:23 +0000)]
update stacker to 0.1.9 to unbreak build on OpenBSD

4 years agoFix link to `map` documentation in example
Faris Sufyan [Sun, 10 May 2020 10:06:30 +0000 (18:06 +0800)]
Fix link to `map` documentation in example

Co-authored-by: Timo <timorcb@gmail.com>
4 years agorebase fallout
Ralf Jung [Mon, 4 May 2020 09:29:16 +0000 (11:29 +0200)]
rebase fallout

4 years agoTypo
Ralf Jung [Wed, 29 Apr 2020 12:04:40 +0000 (14:04 +0200)]
Typo

Co-Authored-By: Oliver Scherer <github35764891676564198441@oli-obk.de>
4 years agofmt
Ralf Jung [Wed, 29 Apr 2020 12:02:41 +0000 (14:02 +0200)]
fmt

4 years agoavoid raising interpreter errors from interning
Ralf Jung [Wed, 29 Apr 2020 10:34:51 +0000 (12:34 +0200)]
avoid raising interpreter errors from interning

4 years agoremove some dead code, and assert we do not swallow allocating errors
Ralf Jung [Wed, 29 Apr 2020 08:14:57 +0000 (10:14 +0200)]
remove some dead code, and assert we do not swallow allocating errors

4 years agoMiri interning: replace ICEs by proper errors, make intern_shallow type signature...
Ralf Jung [Wed, 29 Apr 2020 08:00:22 +0000 (10:00 +0200)]
Miri interning: replace ICEs by proper errors, make intern_shallow type signature more precise

4 years agoRollup merge of #72043 - GuillaumeGomez:clean-up-e0569, r=Dylan-DPC
Ralf Jung [Sun, 10 May 2020 09:34:36 +0000 (11:34 +0200)]
Rollup merge of #72043 - GuillaumeGomez:clean-up-e0569, r=Dylan-DPC

Add missing backtick in E0569 explanation

r? @Dylan-DPC

4 years agoRollup merge of #71945 - GuillaumeGomez:sort-impl-on-foreign-types-section, r=kinniso...
Ralf Jung [Sun, 10 May 2020 09:34:34 +0000 (11:34 +0200)]
Rollup merge of #71945 - GuillaumeGomez:sort-impl-on-foreign-types-section, r=kinnison,ollie27

Sort "implementations on foreign types" section in the sidebar

Fixes #71926.

We were sorting by the ID instead of sorting by the name. They're not in the same order as the implementations but I think it makes more sense this way considering this is what we do for the methods as well.

r? @kinnison

cc @rust-lang/rustdoc

4 years agoRollup merge of #71882 - alexcrichton:update-cc, r=Mark-Simulacrum
Ralf Jung [Sun, 10 May 2020 09:34:32 +0000 (11:34 +0200)]
Rollup merge of #71882 - alexcrichton:update-cc, r=Mark-Simulacrum

Update the `cc` crate

Pulls in updated MSVC detection logic landed in alexcrichton/cc-rs#488

4 years agoRollup merge of #71840 - matthewjasper:drop-trees, r=oli-obk
Ralf Jung [Sun, 10 May 2020 09:34:30 +0000 (11:34 +0200)]
Rollup merge of #71840 - matthewjasper:drop-trees, r=oli-obk

Rework MIR drop tree lowering

This PR changes how drops are generated in MIR construction. This is the first half of the fix for #47949.

Rather than generating the drops for a given unwind/break/continue/return/generator drop path as soon as they are needed, the required drops are recorded and get generated later.

The motivation for this is
* It simplifies the caching scheme, because it's now possible to walk up the currently scheduled drop tree to recover state.
* The basic block order for MIR more closely resembles execution order.

This PR also:
* Highlights cleanup blocks in the graphviz MIR output.
* Removes some unnecessary drop flag assignments.

4 years agouse min_specialization for some rustc crates where it requires no changes
Ralf Jung [Sat, 9 May 2020 11:59:21 +0000 (13:59 +0200)]
use min_specialization for some rustc crates where it requires no changes

4 years agodoc: minus (U+2212) instead of dash (U+002D) for negative infinity
Trevor Spiteri [Sun, 10 May 2020 09:24:06 +0000 (11:24 +0200)]
doc: minus (U+2212) instead of dash (U+002D) for negative infinity

4 years agoadd linking option strip
YI [Sun, 3 May 2020 04:36:12 +0000 (12:36 +0800)]
add linking option strip

move strip option to "Z"

add more strip options, remove strip-debuginfo-if-disabled

merge strip and debuginfo

4 years agoAuto merge of #71775 - petrochenkov:crtcfg, r=matthewjasper
bors [Sun, 10 May 2020 08:25:32 +0000 (08:25 +0000)]
Auto merge of #71775 - petrochenkov:crtcfg, r=matthewjasper

Enable `cfg` predicate for `target_feature = "crt-static"` only if the target supports it

That's what all other `target_feature`s do.