]> git.lizzy.rs Git - rust.git/log
rust.git
5 years agolibarena => 2018
Mazdak Farrokhzad [Sat, 2 Feb 2019 17:18:24 +0000 (18:18 +0100)]
libarena => 2018

5 years agoAuto merge of #56645 - pietroalbini:fix-unused-imports, r=estebank
bors [Mon, 11 Feb 2019 10:34:09 +0000 (10:34 +0000)]
Auto merge of #56645 - pietroalbini:fix-unused-imports, r=estebank

Initial implementation of rustfixable unused_imports lint

This PR adds the initial implementation of rustfixable `unused_imports` lint. The implementation works, but rustfix is not able to apply all the suggestions until https://github.com/rust-lang/rust/issues/53934 is fixed. It also needs https://github.com/rust-lang/rust/pull/58296 to hide the suggested note since it's really useless.

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

<details><summary><code>cargo fix</code> in action on the <code>unused_imports</code> lint</summary>

![screenshot from 2018-12-09 15-49-01](https://user-images.githubusercontent.com/2299951/49698874-3a026080-fbca-11e8-9bf1-24060b6c59c8.png)

</details>

5 years agoAuto merge of #58153 - ljedrz:HirIdify_typeck, r=Zoxc
bors [Mon, 11 Feb 2019 06:03:58 +0000 (06:03 +0000)]
Auto merge of #58153 - ljedrz:HirIdify_typeck, r=Zoxc

Partially Hiridify typeck

Another step towards https://github.com/rust-lang/rust/pull/57578.

5 years agoAuto merge of #58152 - ljedrz:HirIdify_mir, r=Zoxc
bors [Mon, 11 Feb 2019 03:35:22 +0000 (03:35 +0000)]
Auto merge of #58152 - ljedrz:HirIdify_mir, r=Zoxc

Partially HirIdify mir

Another step towards https://github.com/rust-lang/rust/pull/57578.

5 years agoAuto merge of #58358 - pietroalbini:update-cargo, r=Mark-Simulacrum
bors [Mon, 11 Feb 2019 01:05:22 +0000 (01:05 +0000)]
Auto merge of #58358 - pietroalbini:update-cargo, r=Mark-Simulacrum

Bump cargo to 865cb70

Merged PRs:

* Replace util::without_prefix with Path::strip_prefix rust-lang/cargo#6620
* keep track of crates that are whitelisted to be used even if yanked rust-lang/cargo#6611
* Fix default DYLD_FALLBACK_LIBRARY_PATH on MacOS. rust-lang/cargo#6625
* Bail when trying to run "test --doc --no-run" rust-lang/cargo#6628
* In cargo test's help, add that examples are built rust-lang/cargo#6619
* Extract & re-use filter_targets in cargo_compile rust-lang/cargo#6621
* Test cleanup: remove unnecessary with_status(0) rust-lang/cargo#6630
* Fix run's help message rust-lang/cargo#6631
* Some updates to bash completion. rust-lang/cargo#6644
* Introduce Source::download_now rust-lang/cargo#6637
* Switch from unused_imports to deprecated to test unfixable warnings rust-lang/cargo#6649

5 years agoAuto merge of #58361 - GuillaumeGomez:rollup, r=GuillaumeGomez
bors [Sun, 10 Feb 2019 22:35:36 +0000 (22:35 +0000)]
Auto merge of #58361 - GuillaumeGomez:rollup, r=GuillaumeGomez

Rollup of 16 pull requests

Successful merges:

 - #57259 (Update reference of rlibc crate to compiler-builtins crate)
 - #57740 (Use `to_ne_bytes` for converting IPv4Addr to octets)
 - #57926 (Tiny expansion to docs for `core::convert`.)
 - #58157 (Add Cargo.lock automatically adding message)
 - #58203 (rustdoc: display sugared return types for async functions)
 - #58243 (Add trait alias support in rustdoc)
 - #58262 (Add #[must_use] message to Fn* traits)
 - #58295 (std::sys::unix::stdio: explain why we do into_raw)
 - #58297 (Cleanup JS a bit)
 - #58317 (Some writing improvement, conciseness of intro)
 - #58324 (miri: give non-generic functions a stable address)
 - #58332 (operand-to-place copies should never be overlapping)
 - #58345 (When there are multiple filenames, print what got interpreted as filenames)
 - #58346 (rpath computation: explain why we pop())
 - #58350 (Fix failing tidy (line endings on Windows))
 - #58352 (miri value visitor: use `?` in macro)

Failed merges:

r? @ghost

5 years agoRollup merge of #58352 - RalfJung:macro, r=oli-obk
Guillaume Gomez [Sun, 10 Feb 2019 20:45:27 +0000 (21:45 +0100)]
Rollup merge of #58352 - RalfJung:macro, r=oli-obk

miri value visitor: use `?` in macro

5 years agoRollup merge of #58350 - petrochenkov:embed, r=frewsxcv
Guillaume Gomez [Sun, 10 Feb 2019 20:45:25 +0000 (21:45 +0100)]
Rollup merge of #58350 - petrochenkov:embed, r=frewsxcv

Fix failing tidy (line endings on Windows)

Updates to `embedded-book` including https://github.com/rust-embedded/book/pull/127.

5 years agoRollup merge of #58346 - RalfJung:rpath-pop, r=Mark-Simulacrum
Guillaume Gomez [Sun, 10 Feb 2019 20:45:24 +0000 (21:45 +0100)]
Rollup merge of #58346 - RalfJung:rpath-pop, r=Mark-Simulacrum

rpath computation: explain why we pop()

I was quite confused by this code until I got a debug log of what is going on.

5 years agoRollup merge of #58345 - RalfJung:2nd-filename, r=matthewjasper
Guillaume Gomez [Sun, 10 Feb 2019 20:45:22 +0000 (21:45 +0100)]
Rollup merge of #58345 - RalfJung:2nd-filename, r=matthewjasper

When there are multiple filenames, print what got interpreted as filenames

I have written code that crafts command lines for rustc, and when I get "multiple input filenames provided" it can be quite hard to figure out where in this long list of arguments the mistake is hiding.  Probably I passed an argument to a flag that does not expect an argument, but which flag would that be?

This changes the error message to print the first two filenames, to make it easier to debug what is going on.

5 years agoRollup merge of #58332 - RalfJung:miri-copy-nonoverlapping, r=oli-obk
Guillaume Gomez [Sun, 10 Feb 2019 20:45:21 +0000 (21:45 +0100)]
Rollup merge of #58332 - RalfJung:miri-copy-nonoverlapping, r=oli-obk

operand-to-place copies should never be overlapping

This seems to just work (verified with the Miri test suite).

r? @oli-obk

5 years agoRollup merge of #58324 - RalfJung:fn-ptr-eq, r=oli-obk
Guillaume Gomez [Sun, 10 Feb 2019 20:45:20 +0000 (21:45 +0100)]
Rollup merge of #58324 - RalfJung:fn-ptr-eq, r=oli-obk

miri: give non-generic functions a stable address

This makes Miri correctly handle format string parameters despite https://github.com/rust-lang/rust/issues/58320.

Matching Miri PR: https://github.com/solson/miri/pull/626

r? @oli-obk

5 years agoRollup merge of #58317 - hayekr:patch-1, r=frewsxcv
Guillaume Gomez [Sun, 10 Feb 2019 20:45:19 +0000 (21:45 +0100)]
Rollup merge of #58317 - hayekr:patch-1, r=frewsxcv

Some writing improvement, conciseness of intro

Made unstable-features doc more concise in the introduction paragraph

5 years agoRollup merge of #58297 - GuillaumeGomez:cleanup-js, r=QuietMisdreavus
Guillaume Gomez [Sun, 10 Feb 2019 20:45:18 +0000 (21:45 +0100)]
Rollup merge of #58297 - GuillaumeGomez:cleanup-js, r=QuietMisdreavus

Cleanup JS a bit

r? @QuietMisdreavus

5 years agoRollup merge of #58295 - RalfJung:stdio, r=alexcrichton
Guillaume Gomez [Sun, 10 Feb 2019 20:45:16 +0000 (21:45 +0100)]
Rollup merge of #58295 - RalfJung:stdio, r=alexcrichton

std::sys::unix::stdio: explain why we do into_raw

I was quite puzzled why someone would call `into_raw` and then ignore the result.

5 years agoRollup merge of #58262 - taiki-e:must_use, r=estebank
Guillaume Gomez [Sun, 10 Feb 2019 20:45:15 +0000 (21:45 +0100)]
Rollup merge of #58262 - taiki-e:must_use, r=estebank

Add #[must_use] message to Fn* traits

This PR adds `#[must_use]` message to `Fn*` traits.

Related: #57549

r? @estebank

5 years agoRollup merge of #58243 - GuillaumeGomez:trait-alias-docs, r=Manishearth
Guillaume Gomez [Sun, 10 Feb 2019 20:45:13 +0000 (21:45 +0100)]
Rollup merge of #58243 - GuillaumeGomez:trait-alias-docs, r=Manishearth

Add trait alias support in rustdoc

Fixes #57595.

r? @QuietMisdreavus

5 years agoRollup merge of #58203 - euclio:rustdoc-async, r=GuillaumeGomez
Guillaume Gomez [Sun, 10 Feb 2019 20:45:12 +0000 (21:45 +0100)]
Rollup merge of #58203 - euclio:rustdoc-async, r=GuillaumeGomez

rustdoc: display sugared return types for async functions

Fixes #58027.

5 years agoRollup merge of #58157 - h-michael:cargo-lock, r=alexcrichton
Guillaume Gomez [Sun, 10 Feb 2019 20:45:11 +0000 (21:45 +0100)]
Rollup merge of #58157 - h-michael:cargo-lock, r=alexcrichton

Add Cargo.lock automatically adding message

If I execute `cargo +nightly fix`, this change always occurs; cc #58099
r? @Centril

5 years agoRollup merge of #57926 - icefoxen:test-doc-pr, r=frewsxcv
Guillaume Gomez [Sun, 10 Feb 2019 20:45:09 +0000 (21:45 +0100)]
Rollup merge of #57926 - icefoxen:test-doc-pr, r=frewsxcv

Tiny expansion to docs for `core::convert`.

This is not really significant, accept or reject as you wish.  I just want to make sure I understand how the PR process works and that I'm doing it right before doing a bigger one for #33417.

5 years agoRollup merge of #57740 - JakubOnderka:ipv4addr-to_ne_bytes, r=scottmcm
Guillaume Gomez [Sun, 10 Feb 2019 20:45:08 +0000 (21:45 +0100)]
Rollup merge of #57740 - JakubOnderka:ipv4addr-to_ne_bytes, r=scottmcm

Use `to_ne_bytes` for converting IPv4Addr to octets

It is easier and it should be also faster, because [`to_ne_bytes`](https://doc.rust-lang.org/std/primitive.u32.html#method.to_ne_bytes) just calls `mem::transmute`.

5 years agoRollup merge of #57259 - king6cong:master, r=alexcrichton
Guillaume Gomez [Sun, 10 Feb 2019 20:45:07 +0000 (21:45 +0100)]
Rollup merge of #57259 - king6cong:master, r=alexcrichton

Update reference of rlibc crate to compiler-builtins crate

None

5 years agoAuto merge of #58129 - RalfJung:maybe-uninit, r=cramertj
bors [Sun, 10 Feb 2019 20:03:03 +0000 (20:03 +0000)]
Auto merge of #58129 - RalfJung:maybe-uninit, r=cramertj

MaybeUninit: some docs, rename into_inner -> into_initialized, return &mut from set

5 years agofix SGX build failures
Ralf Jung [Sun, 10 Feb 2019 18:08:49 +0000 (19:08 +0100)]
fix SGX build failures

5 years agobump cargo submodule
Pietro Albini [Sun, 10 Feb 2019 17:36:00 +0000 (18:36 +0100)]
bump cargo submodule

5 years agoRemove spotlight for trait aliases and fix nits
Guillaume Gomez [Sun, 10 Feb 2019 15:56:21 +0000 (16:56 +0100)]
Remove spotlight for trait aliases and fix nits

5 years agoit is okay not to use into_inner
Ralf Jung [Sun, 10 Feb 2019 14:27:59 +0000 (15:27 +0100)]
it is okay not to use into_inner

5 years agoAuto merge of #58151 - ljedrz:HirIdify_rustc, r=Zoxc
bors [Sun, 10 Feb 2019 14:30:37 +0000 (14:30 +0000)]
Auto merge of #58151 - ljedrz:HirIdify_rustc, r=Zoxc

Partially HirId-ify rustc

Another step towards https://github.com/rust-lang/rust/pull/57578.

5 years agomiri value visitor: use in macro
Ralf Jung [Sun, 10 Feb 2019 14:16:25 +0000 (15:16 +0100)]
miri value visitor: use  in macro

5 years agoAdd trait aliases to js types
Guillaume Gomez [Thu, 7 Feb 2019 00:02:23 +0000 (01:02 +0100)]
Add trait aliases to js types

5 years agoAdd style for trait aliases
Guillaume Gomez [Thu, 7 Feb 2019 00:02:09 +0000 (01:02 +0100)]
Add style for trait aliases

5 years agoAdd trait alias support in rustdoc
Guillaume Gomez [Tue, 5 Feb 2019 13:27:09 +0000 (14:27 +0100)]
Add trait alias support in rustdoc

5 years agoFix failing tidy (line endings on Windows)
Vadim Petrochenkov [Sun, 10 Feb 2019 13:21:47 +0000 (16:21 +0300)]
Fix failing tidy (line endings on Windows)

5 years agorpath computation: explain why we pop()
Ralf Jung [Sun, 10 Feb 2019 12:05:37 +0000 (13:05 +0100)]
rpath computation: explain why we pop()

5 years agowhen there are multiple filenames, print what got interpreted as 2nd filename
Ralf Jung [Sun, 10 Feb 2019 11:58:08 +0000 (12:58 +0100)]
when there are multiple filenames, print what got interpreted as 2nd filename

5 years agoAuto merge of #58085 - wesleywiser:profiler_2, r=wesleywiser
bors [Sun, 10 Feb 2019 11:18:50 +0000 (11:18 +0000)]
Auto merge of #58085 - wesleywiser:profiler_2, r=wesleywiser

Implement more detailed self profiling

Timing data and cache hits/misses are now recorded at the query level.
This allows us to show detailed per query information such as total time
for each query.

To see detailed query information in the summary pass the `-Z verbose`
flag. For example:

```
rustc -Z self-profile -Z verbose hello_world.rs
```

results in something like:

```md
Self profiling results:

| Phase                                     | Time (ms)      | Time (%) | Queries        | Hits (%)
| ----------------------------------------- | -------------- | -------- | -------------- | --------
| Other                                     |            177 |    54.97 |           8094 |    45.47
| - {time spent not running queries}        |            113 |    35.09 |              0 |     0.00
| - const_eval                              |             16 |     4.97 |             26 |    11.54
| - type_of                                 |              9 |     2.80 |            627 |    27.75
| - const_eval_raw                          |              8 |     2.48 |             22 |     0.00
| - adt_def                                 |              7 |     2.17 |            381 |    11.55
| - visible_parent_map                      |              7 |     2.17 |             99 |    98.99
| - item_attrs                              |              6 |     1.86 |            698 |    50.14
| - item_children                           |              5 |     1.55 |           2815 |     0.00
| - adt_dtorck_constraint                   |              4 |     1.24 |              2 |     0.00
| - adt_destructor                          |              2 |     0.62 |             15 |    86.67
| TypeChecking                              |             53 |    16.46 |           2834 |    79.89
| - trait_impls_of                          |              9 |     2.80 |             65 |    86.15
| - evaluate_obligation                     |              7 |     2.17 |             80 |     2.50
| - const_is_rvalue_promotable_to_static    |              6 |     1.86 |              1 |     0.00
| - is_copy_raw                             |              6 |     1.86 |             29 |    58.62
| - rvalue_promotable_map                   |              6 |     1.86 |              2 |    50.00
| - {time spent not running queries}        |              6 |     1.86 |              0 |     0.00
| - typeck_item_bodies                      |              5 |     1.55 |              1 |     0.00
| - typeck_tables_of                        |              5 |     1.55 |             19 |    94.74
| - dropck_outlives                         |              2 |     0.62 |              1 |     0.00
| - layout_raw                              |              1 |     0.31 |            668 |    87.87
| Linking                                   |             48 |    14.91 |             43 |    46.51
| - {time spent not running queries}        |             48 |    14.91 |              0 |     0.00
| Codegen                                   |             29 |     9.01 |            420 |    61.90
| - {time spent not running queries}        |             16 |     4.97 |              0 |     0.00
| - collect_and_partition_mono_items        |             11 |     3.42 |             13 |    92.31
| - mir_const                               |              1 |     0.31 |              1 |     0.00
| - mir_validated                           |              1 |     0.31 |              3 |    66.67
| Expansion                                 |             14 |     4.35 |              0 |     0.00
| - {time spent not running queries}        |             14 |     4.35 |              0 |     0.00
| BorrowChecking                            |              1 |     0.31 |             12 |    41.67
| - borrowck                                |              1 |     0.31 |              2 |    50.00
| Parsing                                   |              0 |     0.00 |              0 |     0.00

Optimization level: No
Incremental: off
```

<details>
<summary>Rendered</summary>

Self profiling results:

| Phase                                     | Time (ms)      | Time (%) | Queries        | Hits (%)
| ----------------------------------------- | -------------- | -------- | -------------- | --------
| **Other**                                     |           **177** |   **54.97** |   **8094** |  **45.47**
| - {time spent not running queries}        |            113 |    35.09 |              0 |     0.00
| - const_eval                              |             16 |     4.97 |             26 |    11.54
| - type_of                                 |              9 |     2.80 |            627 |    27.75
| - const_eval_raw                          |              8 |     2.48 |             22 |     0.00
| - adt_def                                 |              7 |     2.17 |            381 |    11.55
| - visible_parent_map                      |              7 |     2.17 |             99 |    98.99
| - item_attrs                              |              6 |     1.86 |            698 |    50.14
| - item_children                           |              5 |     1.55 |           2815 |     0.00
| - adt_dtorck_constraint                   |              4 |     1.24 |              2 |     0.00
| - adt_destructor                          |              2 |     0.62 |             15 |    86.67
| TypeChecking                              |             53 |    16.46 |           2834 |    79.89
| - trait_impls_of                          |              9 |     2.80 |             65 |    86.15
| - evaluate_obligation                     |              7 |     2.17 |             80 |     2.50
| - const_is_rvalue_promotable_to_static    |              6 |     1.86 |              1 |     0.00
| - is_copy_raw                             |              6 |     1.86 |             29 |    58.62
| - rvalue_promotable_map                   |              6 |     1.86 |              2 |    50.00
| - {time spent not running queries}        |              6 |     1.86 |              0 |     0.00
| - typeck_item_bodies                      |              5 |     1.55 |              1 |     0.00
| - typeck_tables_of                        |              5 |     1.55 |             19 |    94.74
| - dropck_outlives                         |              2 |     0.62 |              1 |     0.00
| - layout_raw                              |              1 |     0.31 |            668 |    87.87
| Linking                                   |             48 |    14.91 |             43 |    46.51
| - {time spent not running queries}        |             48 |    14.91 |              0 |     0.00
| Codegen                                   |             29 |     9.01 |            420 |    61.90
| - {time spent not running queries}        |             16 |     4.97 |              0 |     0.00
| - collect_and_partition_mono_items        |             11 |     3.42 |             13 |    92.31
| - mir_const                               |              1 |     0.31 |              1 |     0.00
| - mir_validated                           |              1 |     0.31 |              3 |    66.67
| Expansion                                 |             14 |     4.35 |              0 |     0.00
| - {time spent not running queries}        |             14 |     4.35 |              0 |     0.00
| BorrowChecking                            |              1 |     0.31 |             12 |    41.67
| - borrowck                                |              1 |     0.31 |              2 |    50.00
| Parsing                                   |              0 |     0.00 |              0 |     0.00

Optimization level: No
Incremental: off

</details>
cc @nikomatsakis @michaelwoerister @Zoxc

Fixes #54141

5 years agoAuto merge of #58103 - RalfJung:mir-shim-dump, r=eddyb
bors [Sun, 10 Feb 2019 08:52:10 +0000 (08:52 +0000)]
Auto merge of #58103 - RalfJung:mir-shim-dump, r=eddyb

Make -Zdump-mir dump shims

Fixes https://github.com/rust-lang/rust/issues/53532 by (a) making the MIR shim generation use the MIR pass infrastructure, and (b) fixing said infrastructure to handle the fallout.

Cc @eddyb @oli-obk

5 years agoAuto merge of #58339 - Mark-Simulacrum:embedded-book, r=Mark-Simulacrum
bors [Sun, 10 Feb 2019 04:34:12 +0000 (04:34 +0000)]
Auto merge of #58339 - Mark-Simulacrum:embedded-book, r=Mark-Simulacrum

Add EmbeddedBook to test list in bootstrap

r? @alexcrichton

5 years agoAdd EmbeddedBook to test list in bootstrap
Mark Rousskov [Sun, 10 Feb 2019 02:42:23 +0000 (19:42 -0700)]
Add EmbeddedBook to test list in bootstrap

5 years agoAuto merge of #57770 - Zoxc:no-hash-query, r=michaelwoerister
bors [Sun, 10 Feb 2019 01:33:17 +0000 (01:33 +0000)]
Auto merge of #57770 - Zoxc:no-hash-query, r=michaelwoerister

Add a query type which is always marked as red if it runs

This is useful for queries which produce results which are very likely to change if their inputs do.

I also expect this to be useful for end to end queries because 1) we don't need `HashStable` impls and 2) we avoid the overhead of hashing the result of large results like the AST or the HIR map.

r? @michaelwoerister

5 years agoAuto merge of #58065 - alexreg:refactor-smart_resolve_path_fragment, r=petrochenkov
bors [Sat, 9 Feb 2019 23:02:15 +0000 (23:02 +0000)]
Auto merge of #58065 - alexreg:refactor-smart_resolve_path_fragment, r=petrochenkov

Factor out error reporting from `smart_resolve_path_fragment` fn

This function was ridiculously monolithic before. We now have three rather-less-monolithic-and-horrifying functions.

r? @centril

5 years agooperand-to-place copies should never be overlapping
Ralf Jung [Sat, 9 Feb 2019 18:58:41 +0000 (19:58 +0100)]
operand-to-place copies should never be overlapping

5 years agoAuto merge of #57944 - estebank:unclosed-delim-the-quickening, r=oli-obk
bors [Sat, 9 Feb 2019 20:15:57 +0000 (20:15 +0000)]
Auto merge of #57944 - estebank:unclosed-delim-the-quickening, r=oli-obk

Deduplicate mismatched delimiter errors

Delay unmatched delimiter errors until after the parser has run to deduplicate them when parsing and attempt recovering intelligently.

Second attempt at #54029, follow up to #53949. Fix #31528.

5 years agoAuto merge of #57885 - arielb1:xform-probe, r=nikomatsakis
bors [Sat, 9 Feb 2019 15:11:43 +0000 (15:11 +0000)]
Auto merge of #57885 - arielb1:xform-probe, r=nikomatsakis

Avoid committing to autoderef in object method probing

This fixes the "leak" introduced in #57835 (see test for details, also apparently #54252 had no tests for the "leaks" that were fixed in it, so go ahead and add one).

Maybe beta-nominating because regression, but I'm against landing things on beta we don't have to.

r? @nikomatsakis

5 years agomiri: give non-generic functions a stable address
Ralf Jung [Sat, 9 Feb 2019 14:44:54 +0000 (15:44 +0100)]
miri: give non-generic functions a stable address

5 years agoAuto merge of #58207 - nnethercote:intern_lazy_const, r=oli-obk
bors [Sat, 9 Feb 2019 12:38:51 +0000 (12:38 +0000)]
Auto merge of #58207 - nnethercote:intern_lazy_const, r=oli-obk

Make `intern_lazy_const` actually intern its argument.

Currently it just unconditionally allocates it in the arena.

For a "Clean Check" build of the the `packed-simd` benchmark, this
change reduces both the `max-rss` and `faults` counts by 59%; it
slightly (~3%) increases the instruction counts but the `wall-time` is
unchanged.

For the same builds of a few other benchmarks, `max-rss` and `faults`
drop by 1--5%, but instruction counts and `wall-time` changes are in the
noise.

Fixes #57432, fixes #57829.

5 years agofix rebase fallout
Ralf Jung [Sat, 9 Feb 2019 11:19:04 +0000 (12:19 +0100)]
fix rebase fallout

5 years agofix printing closures
Ralf Jung [Tue, 5 Feb 2019 22:40:29 +0000 (23:40 +0100)]
fix printing closures

5 years agofix node classification
Ralf Jung [Tue, 5 Feb 2019 20:49:53 +0000 (21:49 +0100)]
fix node classification

5 years agofix --emit=mir: StructCtors are functions
Ralf Jung [Sun, 3 Feb 2019 13:09:56 +0000 (14:09 +0100)]
fix --emit=mir: StructCtors are functions

5 years agodisambiguate filenames of multiple drop shims being dumped
Ralf Jung [Sun, 3 Feb 2019 12:31:50 +0000 (13:31 +0100)]
disambiguate filenames of multiple drop shims being dumped

5 years agopass full InstanceDef to run_passes
Ralf Jung [Sun, 3 Feb 2019 10:51:07 +0000 (11:51 +0100)]
pass full InstanceDef to run_passes

5 years agofix rebase fallout: AnonConsts are Consts, and Methods are functions
Ralf Jung [Sun, 3 Feb 2019 09:06:57 +0000 (10:06 +0100)]
fix rebase fallout: AnonConsts are Consts, and Methods are functions

5 years agofix dumping MIR from another crate
Ralf Jung [Sat, 2 Feb 2019 15:59:20 +0000 (16:59 +0100)]
fix dumping MIR from another crate

5 years agouse pass infrastructure for mir shims, so that they can get dumped
Ralf Jung [Thu, 22 Nov 2018 16:17:45 +0000 (17:17 +0100)]
use pass infrastructure for mir shims, so that they can get dumped

5 years agoAuto merge of #57617 - mark-i-m:multiple-matcher-bindings, r=petrochenkov
bors [Sat, 9 Feb 2019 09:48:41 +0000 (09:48 +0000)]
Auto merge of #57617 - mark-i-m:multiple-matcher-bindings, r=petrochenkov

Error on duplicate matcher bindings

fix  #57593

This should not be merged without a crater run and maybe an FCP. Discussion is ongoing at  #57593.

TODO:
- [x] write tests
- [x] crater run
- [x] ~maybe need edition gating?~ not for 1 regression /centril

r? @petrochenkov

5 years agoSome writing improvement, conciseness of intro
Robert Hayek [Sat, 9 Feb 2019 05:46:27 +0000 (00:46 -0500)]
Some writing improvement, conciseness of intro

5 years agoAuto merge of #57184 - varkor:deny-warnings-lib, r=Mark-Simulacrum
bors [Sat, 9 Feb 2019 03:54:31 +0000 (03:54 +0000)]
Auto merge of #57184 - varkor:deny-warnings-lib, r=Mark-Simulacrum

Deny warnings in libcore and libstd

This probably fixes https://github.com/rust-lang/rust/issues/57178 (though there may still be some crates that need warnings denied). At least after this change, rustc currently produces no warnings during compilation.

r? @oli-obk

5 years agoAuto merge of #58316 - Centril:rollup, r=Centril
bors [Sat, 9 Feb 2019 01:04:13 +0000 (01:04 +0000)]
Auto merge of #58316 - Centril:rollup, r=Centril

Rollup of 18 pull requests

Successful merges:

 - #58091 (Transition compiletest to Rust 2018)
 - #58115 (Transition rustdoc to 2018 edition)
 - #58120 (Transition build_helper to 2018 edition)
 - #58222 (librustc_allocator => 2018)
 - #58233 (librustc_save_analysis => 2018)
 - #58245 (librustc_lint => 2018)
 - #58247 (librustc_passes => 2018)
 - #58251 (Transition librustc_traits to 2018 edition)
 - #58255 (librustc_metadata => 2018)
 - #58256 (librustc_cratesio_shim => 2018)
 - #58257 (librustc_target => 2018)
 - #58259 (librustc_codegen_utils => 2018)
 - #58260 (librustc_borrowck => 2018)
 - #58261 (librustc_incremental => 2018)
 - #58265 (librustc_mir => 2018)
 - #58275 (libcore, liballoc: disable tests in Miri)
 - #58285 (error_index_generator => 2018)
 - #58312 (librustc_data_structures => 2018)

Failed merges:

r? @ghost

5 years agoRollup merge of #58312 - taiki-e:librustc_data_structures-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:06 +0000 (00:16 +0100)]
Rollup merge of #58312 - taiki-e:librustc_data_structures-2018, r=Centril

librustc_data_structures => 2018

Transitions `librustc_data_structures` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58285 - taiki-e:error_index_generator-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:05 +0000 (00:16 +0100)]
Rollup merge of #58285 - taiki-e:error_index_generator-2018, r=Centril

error_index_generator => 2018

Transitions `error_index_generator` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58275 - RalfJung:miri-test-libcore, r=Mark-Simulacrum
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:04 +0000 (00:16 +0100)]
Rollup merge of #58275 - RalfJung:miri-test-libcore, r=Mark-Simulacrum

libcore, liballoc: disable tests in Miri

I am going to run the libcore and liballoc unit test suites in Miri.  Not all tests pass.  This PR disables a whole bunch of tests when running in Miri, to get us to a baseline from which I can investigate failures.

Cc @SimonSapin @alexcrichton

5 years agoRollup merge of #58265 - taiki-e:librustc_mir-2018, r=matthewjasper
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:03 +0000 (00:16 +0100)]
Rollup merge of #58265 - taiki-e:librustc_mir-2018, r=matthewjasper

librustc_mir => 2018

Transitions `librustc_mir` to Rust 2018; cc #58099

TODO: ~~elided_lifetimes_in_paths~~

r? @Centril

5 years agoRollup merge of #58261 - taiki-e:librustc_incremental-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:02 +0000 (00:16 +0100)]
Rollup merge of #58261 - taiki-e:librustc_incremental-2018, r=Centril

librustc_incremental => 2018

Transitions `librustc_incremental` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58260 - taiki-e:librustc_borrowck-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:16:01 +0000 (00:16 +0100)]
Rollup merge of #58260 - taiki-e:librustc_borrowck-2018, r=Centril

librustc_borrowck => 2018

Transitions `librustc_borrowck` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58259 - taiki-e:librustc_codegen_utils-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:59 +0000 (00:15 +0100)]
Rollup merge of #58259 - taiki-e:librustc_codegen_utils-2018, r=Centril

librustc_codegen_utils => 2018

Transitions `librustc_codegen_utils` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58257 - taiki-e:librustc_target-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:58 +0000 (00:15 +0100)]
Rollup merge of #58257 - taiki-e:librustc_target-2018, r=Centril

librustc_target => 2018

Transitions `librustc_target` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58256 - taiki-e:librustc_cratesio_shim-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:57 +0000 (00:15 +0100)]
Rollup merge of #58256 - taiki-e:librustc_cratesio_shim-2018, r=Centril

librustc_cratesio_shim => 2018

Transitions `librustc_cratesio_shim` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58255 - taiki-e:librustc_metadata-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:55 +0000 (00:15 +0100)]
Rollup merge of #58255 - taiki-e:librustc_metadata-2018, r=Centril

librustc_metadata => 2018

Transitions `librustc_metadata` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58251 - h-michael:librustc_traits-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:54 +0000 (00:15 +0100)]
Rollup merge of #58251 - h-michael:librustc_traits-2018, r=Centril

Transition librustc_traits to 2018 edition

Transitions librustc_traits to Rust 2018; cc #58099
r? @Centril

5 years agoRollup merge of #58247 - taiki-e:librustc_passes-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:53 +0000 (00:15 +0100)]
Rollup merge of #58247 - taiki-e:librustc_passes-2018, r=Centril

librustc_passes => 2018

Transitions `librustc_passes` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58245 - taiki-e:librustc_lint-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:52 +0000 (00:15 +0100)]
Rollup merge of #58245 - taiki-e:librustc_lint-2018, r=Centril

librustc_lint => 2018

Transitions `librustc_lint` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58233 - taiki-e:librustc_save_analysis-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:50 +0000 (00:15 +0100)]
Rollup merge of #58233 - taiki-e:librustc_save_analysis-2018, r=Centril

librustc_save_analysis => 2018

Transitions `librustc_save_analysis` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58222 - taiki-e:librustc_allocator-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:49 +0000 (00:15 +0100)]
Rollup merge of #58222 - taiki-e:librustc_allocator-2018, r=Centril

librustc_allocator => 2018

Transitions `librustc_allocator` to Rust 2018; cc #58099

r? @Centril

5 years agoRollup merge of #58120 - h-michael:build_helper-theme-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:48 +0000 (00:15 +0100)]
Rollup merge of #58120 - h-michael:build_helper-theme-2018, r=Centril

Transition build_helper to 2018 edition

Transitions build_helper to Rust 2018; cc #58099
r? @Centril

5 years agoRollup merge of #58115 - h-michael:rustdoc-2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:46 +0000 (00:15 +0100)]
Rollup merge of #58115 - h-michael:rustdoc-2018, r=Centril

Transition rustdoc to 2018 edition

Transitions rustdoc to Rust 2018; cc #58099

5 years agoRollup merge of #58091 - phansch:compiletest2018, r=Centril
Mazdak Farrokhzad [Fri, 8 Feb 2019 23:15:44 +0000 (00:15 +0100)]
Rollup merge of #58091 - phansch:compiletest2018, r=Centril

Transition compiletest to Rust 2018

This transitions `src/tools/compiletest` to Rust 2018.

cc #58099

5 years agoAuto merge of #58161 - davidtwco:issue-57960, r=arielb1
bors [Fri, 8 Feb 2019 17:13:56 +0000 (17:13 +0000)]
Auto merge of #58161 - davidtwco:issue-57960, r=arielb1

Lower constant patterns with ascribed types.

Fixes #57960.

This PR fixes a bug introduced by #55937 which started checking user
type annotations for associated type patterns. Where lowering a
associated constant expression would previously return a
`PatternKind::Constant`, it now returns a `PatternKind::AscribeUserType`
with a `PatternKind::Constant` inside, this PR unwraps that to
access the constant pattern inside and behaves as before.

r? @pnkfelix

5 years agolibrustc_data_structures => 2018
Taiki Endo [Fri, 8 Feb 2019 16:36:22 +0000 (01:36 +0900)]
librustc_data_structures => 2018

5 years agoDeny warnings in std stage 0
varkor [Fri, 8 Feb 2019 15:44:50 +0000 (16:44 +0100)]
Deny warnings in std stage 0

5 years agoAuto merge of #58294 - hrls:master, r=GuillaumeGomez
bors [Fri, 8 Feb 2019 14:16:14 +0000 (14:16 +0000)]
Auto merge of #58294 - hrls:master, r=GuillaumeGomez

fix rustdoc JS

#58290

5 years agolibrustc_incremental => 2018
Taiki Endo [Fri, 8 Feb 2019 12:16:35 +0000 (21:16 +0900)]
librustc_incremental => 2018

5 years agolibrustc_borrowck => 2018
Taiki Endo [Fri, 8 Feb 2019 12:11:10 +0000 (21:11 +0900)]
librustc_borrowck => 2018

5 years agolibrustc_codegen_utils => 2018
Taiki Endo [Fri, 8 Feb 2019 12:06:07 +0000 (21:06 +0900)]
librustc_codegen_utils => 2018

5 years agolibrustc_target => 2018
Taiki Endo [Fri, 8 Feb 2019 12:00:07 +0000 (21:00 +0900)]
librustc_target => 2018

5 years agolibrustc_cratesio_shim => 2018
Taiki Endo [Fri, 8 Feb 2019 11:55:12 +0000 (20:55 +0900)]
librustc_cratesio_shim => 2018

5 years agolibrustc_metadata => 2018
Taiki Endo [Fri, 8 Feb 2019 11:50:17 +0000 (20:50 +0900)]
librustc_metadata => 2018

5 years agolibrustc_passes => 2018
Taiki Endo [Fri, 8 Feb 2019 11:40:49 +0000 (20:40 +0900)]
librustc_passes => 2018

5 years agoCleanup JS a bit
Guillaume Gomez [Fri, 8 Feb 2019 11:38:47 +0000 (12:38 +0100)]
Cleanup JS a bit

5 years agolibrustc_lint => 2018
Taiki Endo [Fri, 8 Feb 2019 11:35:41 +0000 (20:35 +0900)]
librustc_lint => 2018

5 years agoRemove #[macro_use] extern crate bitflags
Taiki Endo [Fri, 8 Feb 2019 11:13:12 +0000 (20:13 +0900)]
Remove #[macro_use] extern crate bitflags

5 years agoUse real try blocks
Taiki Endo [Fri, 8 Feb 2019 11:08:08 +0000 (20:08 +0900)]
Use real try blocks

5 years agoRevert removed #![feature(nll)]
Taiki Endo [Fri, 8 Feb 2019 10:56:52 +0000 (19:56 +0900)]
Revert removed #![feature(nll)]

5 years agostd::sys::unix::stdio: explain why we do into_raw
Ralf Jung [Fri, 8 Feb 2019 10:41:01 +0000 (11:41 +0100)]
std::sys::unix::stdio: explain why we do into_raw

5 years agoAuto merge of #58213 - Mark-Simulacrum:fix-checktools, r=alexcrichton
bors [Fri, 8 Feb 2019 10:17:01 +0000 (10:17 +0000)]
Auto merge of #58213 - Mark-Simulacrum:fix-checktools, r=alexcrichton

Add embedded book to test such that checktools works

r? @alexcrichton

FWIW this doesn't attempt to make sure we don't break check tools again -- we intentionally make the bash script not exit when x.py fails so we'd need some special case handling so for now I'm just fixing the bug itself, not its cause.

5 years agofix rustdoc JS
hrls [Fri, 8 Feb 2019 09:47:20 +0000 (12:47 +0300)]
fix rustdoc JS

5 years agoFix nll test output
Esteban Küber [Fri, 8 Feb 2019 09:16:56 +0000 (01:16 -0800)]
Fix nll test output

5 years agounused_imports: update tests
Pietro Albini [Sun, 9 Dec 2018 16:40:49 +0000 (17:40 +0100)]
unused_imports: update tests

5 years agoerror_index_generator => 2018
Taiki Endo [Fri, 8 Feb 2019 07:44:15 +0000 (16:44 +0900)]
error_index_generator => 2018

5 years agoAllow a dirty MirBuilt for make_extern and make_method_extern
John Kåre Alsaker [Fri, 8 Feb 2019 03:30:27 +0000 (04:30 +0100)]
Allow a dirty MirBuilt for make_extern and make_method_extern