Commit graph

89278 commits

Author SHA1 Message Date
Mazdak Farrokhzad a4964500a2
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-13 10:54:13 +01:00
Mazdak Farrokhzad ee3371ec91
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-12 10:41:39 +01:00
Mazdak Farrokhzad 4c0a3d5894
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-12 10:40:22 +01:00
Mazdak Farrokhzad 8a026f1cdd
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-12 10:40:14 +01:00
Mazdak Farrokhzad 73921f67e9
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-12 10:40:07 +01:00
Who? Me?! fb3ae5738a
Update RELEASES.md
Co-Authored-By: Aaronepower <Aaronepower@users.noreply.github.com>
2019-02-09 11:39:06 +01:00
Aaron Power 6c71e7d3f7
Update RELEASES.md 2019-02-07 10:05:15 +01:00
Aaron Power 50be479475 Updated RELEASES.md for 1.33.0 2019-02-06 15:46:39 +01:00
bors b139669f37 Auto merge of #56123 - oli-obk:import_miri_from_future, r=eddyb
Add a forever unstable opt-out of const qualification checks

r? @eddyb

cc @RalfJung @Centril

basically a forever unstable way to screw with const things in horribly unsafe, unsound and incoherent ways.

Note that this does *not* affect miri except by maybe violating assumptions that miri makes. But there's no change in how miri evaluates things.
2019-02-06 08:42:46 +00:00
bors 2596bc1368 Auto merge of #58061 - nnethercote:overhaul-syntax-Folder, r=petrochenkov
Overhaul `syntax::fold::Folder`.

This PR changes `syntax::fold::Folder` from a functional style
(where most methods take a `T` and produce a new `T`) to a more
imperative style (where most methods take and modify a `&mut T`), and
renames it `syntax::mut_visit::MutVisitor`.

This makes the code faster and more concise.
2019-02-06 06:01:37 +00:00
bors 0e5a209959 Auto merge of #58058 - QuietMisdreavus:use-attr, r=GuillaumeGomez
rustdoc: don't try to get a DefId for a Def that doesn't have one

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

The compiler allows you to write a `use` statement for a built-in non-macro attribute, since `use proc_macro` can apply to both the `proc_macro` crate and the `#[proc_macro]` attribute. However, if you write a use statement for something that *doesn't* have this crossover, rustdoc will try to use it the same way as anything else... which resulted in an ICE because it tried to pull a DefId for something that didn't have one. This PR makes rustdoc skip those lookups when it encounters them, allowing it to properly process and render these imports.
2019-02-06 03:07:04 +00:00
Nicholas Nethercote bfcbd235a2 Rename fold.rs as mut_visit.rs. 2019-02-06 09:10:05 +11:00
bors 65e647cfe7 Auto merge of #58131 - ehuss:update-cargo, r=alexcrichton
Update cargo

7 commits in 245818076052dd7178f5bb7585f5aec5b6c1e03e..4e74e2fc0908524d17735c768067117d3e84ee9c
2019-01-27 15:17:26 +0000 to 2019-02-02 17:48:44 +0000
- Fix overlapping progress with stdout. (rust-lang/cargo#6618)
- Improve progress bar flickering. (rust-lang/cargo#6615)
- Add detail to multiple rename deps (rust-lang/cargo#6603)
- Fix race condition in local registry crate unpacking (rust-lang/cargo#6591)
- Revert "Make incremental compilation the default for all profiles." (rust-lang/cargo#6610)
- Fixup the docs on crate-type (rust-lang/cargo#6606)
- Document that owner --add now just invites (rust-lang/cargo#6604)
2019-02-05 22:08:47 +00:00
Nicholas Nethercote 9fcb1658ab Overhaul syntax::fold::Folder.
This commit changes `syntax::fold::Folder` from a functional style
(where most methods take a `T` and produce a new `T`) to a more
imperative style (where most methods take and modify a `&mut T`), and
renames it `syntax::mut_visit::MutVisitor`.

The first benefit is speed. The functional style does not require any
reallocations, due to the use of `P::map` and
`MoveMap::move_{,flat_}map`. However, every field in the AST must be
overwritten; even those fields that are unchanged are overwritten with
the same value. This causes a lot of unnecessary memory writes. The
imperative style reduces instruction counts by 1--3% across a wide range
of workloads, particularly incremental workloads.

The second benefit is conciseness; the imperative style is usually more
concise. E.g. compare the old functional style:
```
fn fold_abc(&mut self, abc: ABC) {
    ABC {
        a: fold_a(abc.a),
        b: fold_b(abc.b),
        c: abc.c,
    }
}
```
with the imperative style:
```
fn visit_abc(&mut self, ABC { a, b, c: _ }: &mut ABC) {
    visit_a(a);
    visit_b(b);
}
```
(The reductions get larger in more complex examples.)

Overall, the patch removes over 200 lines of code -- even though the new
code has more comments -- and a lot of the remaining lines have fewer
characters.

Some notes:

- The old style used methods called `fold_*`. The new style mostly uses
  methods called `visit_*`, but there are a few methods that map a `T`
  to something other than a `T`, which are called `flat_map_*` (`T` maps
  to multiple `T`s) or `filter_map_*` (`T` maps to 0 or 1 `T`s).

- `move_map.rs`/`MoveMap`/`move_map`/`move_flat_map` are renamed
  `map_in_place.rs`/`MapInPlace`/`map_in_place`/`flat_map_in_place` to
  reflect their slightly changed signatures.

- Although this commit renames the `fold` module as `mut_visit`, it
  keeps it in the `fold.rs` file, so as not to confuse git. The next
  commit will rename the file.
2019-02-06 09:06:27 +11:00
Eric Huss 55917ba0e7 Update cargo 2019-02-05 11:17:23 -08:00
bors 4b1e39b7b3 Auto merge of #57851 - Aaron1011:fix/clean-lifetime, r=GuillaumeGomez
Don't try to clean predicates involving ReErased

There's nothing to render when we have a bound involving ReErased (either
a type or region outliving it), so we don't attempt to generate a clean
WherePredicate

Fixes #57806

I haven't been able to come up with a minimized reproduction for the issue, but I've confirmed that this allows the docs to build for `parqet-rs`
2019-02-05 19:12:11 +00:00
bors 8bf7fda6b5 Auto merge of #58189 - kennytm:rollup, r=kennytm
Rollup of 23 pull requests

Successful merges:

 - #58001 (proc_macro: make `TokenStream::from_streams` pre-allocate its vector.)
 - #58096 (Transition linkchecker to 2018 edition)
 - #58097 (Transition remote test to Rust 2018)
 - #58106 (libfmt_macros => 2018)
 - #58107 (libgraphviz => 2018)
 - #58108 (Add NVPTX target to a build manifest)
 - #58109 (librustc_privacy => 2018)
 - #58112 (libpanic_abort => 2018)
 - #58113 (Transition build-manifest to 2018 edition)
 - #58114 (Transition tidy and unstable-book-gen to 2018 edition)
 - #58116 (Include the span of attributes of the lhs to the span of the assignment expression)
 - #58117 (Transition rustdoc-theme to 2018 edition)
 - #58128 (libunwind => 2018)
 - #58138 (Fix #58101)
 - #58139 (hir: add more HirId methods)
 - #58141 (Remove weasel word in docs for iter's take_while())
 - #58142 (Remove stray FIXME)
 - #58145 (Add #[must_use] to core::task::Poll)
 - #58162 (Add more debugging code to track down appveyor 259 exit code)
 - #58169 (Update contributor name in .mailmap)
 - #58172 (update split docs)
 - #58182 (SGX target: handle empty user buffers correctly)
 - #58186 (Add Rustlings to the doc index)

Failed merges:

r? @ghost
2019-02-05 16:22:26 +00:00
kennytm c23871a4c4
Rollup merge of #58186 - komaeda:docs/integrate-rustlings, r=steveklabnik
Add Rustlings to the doc index

r? @steveklabnik
2019-02-06 00:29:21 +09:00
kennytm b3f814fd30
Rollup merge of #58182 - jethrogb:jb/sgx-bytebuffer-len-0, r=joshtriplett
SGX target: handle empty user buffers correctly

Also, expose correct items in `os::fortanix_sgx::usercalls::alloc`

* [read_alloc documentation](https://edp.fortanix.com/docs/api/fortanix_sgx_abi/struct.Usercalls.html#method.read_alloc)
* [Clarified ByteBuffer documentation](https://github.com/fortanix/rust-sgx/pull/94/files#diff-ca843ad9e25cacd63a80579c0f7efa56)

r? @joshtriplett
2019-02-06 00:29:20 +09:00
kennytm 7e72d06c7d
Rollup merge of #58172 - garyemerson:patch-1, r=steveklabnik
update split docs

Some confusion about split popped up at https://news.ycombinator.com/item?id=19080931 since the docs sorta sound like `&str`, `char` and closures are the only types that can be patterns.

cc @steveklabnik
2019-02-06 00:29:19 +09:00
kennytm 5f17ce24bd
Rollup merge of #58169 - boringcactus:patch-1, r=alexcrichton
Update contributor name in .mailmap

following up on email correspondence with @steveklabnik
2019-02-06 00:29:17 +09:00
kennytm 4c243e2c3d
Rollup merge of #58162 - pietroalbini:track-259, r=alexcrichton
Add more debugging code to track down appveyor 259 exit code

cc https://github.com/rust-lang/rust/issues/58160
r? @alexcrichton
2019-02-06 00:29:16 +09:00
kennytm 64f0032a37
Rollup merge of #58145 - taiki-e:poll, r=cramertj
Add #[must_use] to core::task::Poll

cc rust-lang/rfcs#2592

r? @withoutboats
2019-02-06 00:29:15 +09:00
kennytm ff097ca773
Rollup merge of #58142 - jethrogb:jb/sgx-rwlock, r=joshtriplett
Remove stray FIXME

These were copied from the WebAssembly implementation, and later commented. There is nothing to be fixed, RWLock is Send/Sync because all member fields are Send/Sync.

r? @joshtriplett
2019-02-06 00:29:13 +09:00
kennytm f107710afb
Rollup merge of #58141 - lukaslueg:patch-1, r=steveklabnik
Remove weasel word in docs for iter's take_while()

The phrase "... or some similar thing." is very vague and contributes nothing to understanding the example. Simply removed.
2019-02-06 00:29:11 +09:00
kennytm 3fc7373eff
Rollup merge of #58139 - ljedrz:HirIdification_phase_2.5, r=Zoxc
hir: add more HirId methods

Adds a few more methods operating on `HirId` instead of `NodeId` with the intention of replacing the old ones in the near future.

r? @Zoxc
2019-02-06 00:29:10 +09:00
kennytm 3abb03fdb3
Rollup merge of #58138 - ishitatsuyuki:stability-delay, r=estebank
Fix #58101
2019-02-06 00:29:08 +09:00
kennytm a35dac2c5c
Rollup merge of #58128 - taiki-e:libunwind-2018, r=Centril
libunwind => 2018

Transitions `libunwind` to Rust 2018; cc #58099

r? @Centril
2019-02-06 00:29:05 +09:00
kennytm 3dbdd692cc
Rollup merge of #58117 - h-michael:rustdoc-theme-2018, r=Centril
Transition rustdoc-theme to 2018 edition

Transitions rustdoc-theme to Rust 2018; cc #58099
2019-02-06 00:29:03 +09:00
kennytm 757c4407db
Rollup merge of #58116 - topecongiro:wrong-span-assignment, r=petrochenkov
Include the span of attributes of the lhs to the span of the assignment expression

This PR adds the span of attributes of the lhs to the span of the assignment expression. Currently with the following code, `#[attr]` is not included to the span of the assignment (`foo = true`).

```rust
#[attr]
foo = true;
```
The rational behind this change is that as libsyntax user I expect the span of the parent node includes every span of child nodes.

cc https://github.com/rust-lang/rustfmt/issues/3313, https://github.com/rust-lang/rust/issues/15701.
2019-02-06 00:29:02 +09:00
kennytm 3f731d56b6
Rollup merge of #58114 - h-michael:tidy-unstable-book-gen-2018, r=Centril
Transition tidy and unstable-book-gen to 2018 edition

Transitions tidy and unstable-book-gen to Rust 2018; cc #58099
2019-02-06 00:29:00 +09:00
kennytm b9def8ee64
Rollup merge of #58113 - h-michael:build-manifest-2018, r=alexcrichton
Transition build-manifest to 2018 edition

#58099
2019-02-06 00:28:58 +09:00
kennytm c4af395cb1
Rollup merge of #58112 - Centril:libpanic_abort-2018, r=oli-obk
libpanic_abort => 2018

Transitions `libpanic_abort` to Rust 2018; cc #58099

r? @oli-obk
2019-02-06 00:28:57 +09:00
kennytm 49509a506c
Rollup merge of #58109 - Centril:librustc_privacy-2018, r=oli-obk
librustc_privacy => 2018

Transitions `librustc_privacy` to Rust 2018; cc #58099

r? @oli-obk
2019-02-06 00:28:56 +09:00
kennytm 18e5c7a370
Rollup merge of #58108 - denzp:nvptx-manifest, r=alexcrichton
Add NVPTX target to a build manifest

Include `nvptx64-nvidia-cuda` target to a build manifest. I forgot this step at my first take on adding the target (#57937).

Hopefully, this is the only reason why `rustup target add nvptx64-nvidia-cuda` doesn't work 🙁

r? @alexcrichton
2019-02-06 00:28:54 +09:00
kennytm ff7ab33027
Rollup merge of #58107 - Centril:libgraphviz-2018, r=oli-obk
libgraphviz => 2018

Transitions `libgraphviz` to Rust 2018; cc #58099

r? @oli-obk
2019-02-06 00:28:53 +09:00
kennytm 06c9fe9641
Rollup merge of #58106 - Centril:libfmt_macros-2018, r=oli-obk
libfmt_macros => 2018

Transitions `libfmt_macros` to Rust 2018; cc https://github.com/rust-lang/rust/issues/58099

r? @oli-obk
2019-02-06 00:28:52 +09:00
kennytm e1f4833f1a
Rollup merge of #58097 - h-michael:remote-test-2018, r=alexcrichton
Transition remote test to Rust 2018

Only updating Cargo.toml
2019-02-06 00:28:50 +09:00
kennytm da3a2fb980
Rollup merge of #58096 - h-michael:linkchecker-2018, r=Centril
Transition linkchecker to 2018 edition

Transition `src/tools/linkchecker` to Rust 2018.

#58099
2019-02-06 00:28:49 +09:00
kennytm a1ec22f6dd
Rollup merge of #58001 - pnkfelix:issue-57735-proc-macro-with-large-tokenstream-slow, r=eddyb
proc_macro: make `TokenStream::from_streams` pre-allocate its vector.

This requires a pre-pass over the input streams. But that is cheap compared to the quadratic blowup associated with reallocating the accumulating vector on-the-fly.

Fix #57735
2019-02-06 00:28:46 +09:00
liv 014ffa3ac9 Add Rustlings to the doc index 2019-02-05 15:32:59 +01:00
Jethro Beekman d89ebdd475 Expose correct items in os::fortanix_sgx::usercalls::alloc 2019-02-05 16:19:20 +05:30
Jethro Beekman 4c8c0fc1e2 SGX target: handle empty user buffers correctly 2019-02-05 16:19:05 +05:30
Pietro Albini 2bfb4b336f
add even more debugging code to track down appveyor 259 exit code 2019-02-05 08:47:52 +01:00
bors b2c6b8c29f Auto merge of #57973 - davidtwco:issue-52891, r=estebank
Add suggestion for duplicated import.

Fixes #52891.

This PR adds a suggestion when a import is duplicated (ie. the same name
is used twice trying to import the same thing) to remove the second
import.
2019-02-05 05:14:15 +00:00
Nicholas Nethercote 970b5d189a Various improvements in Folder impls. 2019-02-05 15:18:29 +11:00
Nicholas Nethercote 372fe84a83 Streamline Folder some more.
By eliminating some unnecessary methods, and moving/renaming some
functions that look like they might be methods but aren't.
2019-02-05 15:13:12 +11:00
Nicholas Nethercote 473095345b Neaten up fold_crate. 2019-02-05 15:12:15 +11:00
Nicholas Nethercote 8909f70a32 Change fold_qpath to fold_qself.
It's simpler that way.
2019-02-05 15:11:52 +11:00
Nicholas Nethercote f97e896fd6 Simplify fold_attribute.
It doesn't need to return an `Option`.
2019-02-05 15:11:27 +11:00