-
Notifications
You must be signed in to change notification settings - Fork 12.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Rollup of 13 pull requests #65548
Rollup of 13 pull requests #65548
Conversation
Instead of instaling OCaml bindings in a location where installation will not fail, don't build them in the first place.
This wins 3% on `unicode_normalization`.
The commit also removes the debug statement, because they annoyed me. This change wins another 1% on `unicode_normalization`, at least partly because it no longer needs to increment `iteration`.
Building Servo with a recent Nightly produces: ```rust warning: use of deprecated attribute `plugin`: compiler plugins are deprecated. See rust-lang#29597 --> components/script/lib.rs:14:1 | 14 | #![plugin(script_plugins)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove this attribute | = note: `#[warn(deprecated)]` on by default ``` First, linking to rust-lang#29597 is not ideal since there is pretty much no discussion there of the deprecation and what can be used instead. This PR changes the link to the deprecation PR which does have more discussion. Second, the “remove this attribute” suggestion is rather unhelpful. Just because a feature is deprecated doesn’t mean that simply removing its use without a replacement is acceptable. In the case of custom lint, there is no replacement available. Prefixing a message with “help:” when telling users that they’re screwed honestly feels disrespectful. This PR also changes the message to be more factual.
Co-Authored-By: Mark Rousskov <mark.simulacrum@gmail.com>
The current code has this impl: ``` impl<T: Into<TokenStream>> iter::FromIterator<T> for TokenStream ``` If given an `IntoIterator<Item = TokenTree>`, it will convert each individual `TokenTree` to a `TokenStream` (at the cost of two allocations: a `Vec` and an `Lrc`). It will then merge those `TokenStream`s into a single `TokenStream`. This is inefficient. This commit changes the impl to this less general one: ``` impl iter::FromIterator<TokenTree> for TokenStream ``` It collects the `TokenTree`s into a single `Vec` first and then converts that to a `TokenStream` by wrapping it in a single `Lrc`. The previous generality was unnecessary; no other code needs changing. This change speeds up several benchmarks by up to 4%.
Because most of the call sites have an easier time working with a `TokenTree` instead of a `TokenStream`.
Likewise for `NestedMetaItem::tokens()`. Also, add `MetaItemKind::token_trees_and_joints()`, which `MetaItemKind::tokens()` now calls. This avoids some unnecessary `TokenTree` to `TokenStream` conversions, and removes the need for the clumsy `TokenStream::append_to_tree_and_joint_vec()`.
Document JSON message output. This documents the JSON messages in the rustc book.
Disable Go and OCaml bindings when building LLVM Instead of instaling OCaml bindings in a location where installation will not fail, don't build them in the first place.
…-E0575, r=kinnison Add long error explanation for E0575 Part of rust-lang#61137.
…komatsakis Add more coherence tests I've wrote the missing test cases listed in [this google doc](https://docs.google.com/spreadsheets/d/1WlroTEXE6qxxGvEOhICkUpqguYZP9YOZEvnmEtSNtM0/edit#gid=0) > The other thing that might be useful is to rename the existing tests so they all fit the new naming scheme we were using. I'm not entirely sure how to do this. If everything from the google sheet is covered could I just remove the remaining tests in `src/test/ui/coherence` or is there something in there that should remain? cc rust-lang#63599 r? @nikomatsakis
…Tree-to-TokenStream-conversions, r=petrochenkov Avoid unnecessary `TokenTree` to `TokenStream` conversions A `TokenStream` contains any number of `TokenTrees`. Therefore, a single `TokenTree` can be promoted to a `TokenStream`. But doing so costs two allocations: one for the single-element `Vec`, and one for the `Lrc`. (An `IsJoint` value also must be added; the default is `NonJoint`.) The current code converts `TokenTree`s to `TokenStream`s unnecessarily in a few places. This PR removes some of these unnecessary conversions, both simplifying the code and speeding it up. r? @petrochenkov
…sakis Use a sharded dep node to dep node index map Split out from rust-lang#61845 and based on rust-lang#63756. r? @nikomatsakis
…size, r=nikomatsakis Speed up `LexicalResolve::expansion()` A couple of improvements that speed up `unicode_normalization` by about 4%. The first commit was enabled by the improvements to `BitSet` iteration in rust-lang#65425. r? @nikomatsakis
…-E0584, r=kinnison Add long error explanation for E0584 Part of rust-lang#61137. r? @kinnison
properly document panics in div_euclid and rem_euclid For signed numbers, document that `div_euclid` and `rem_euclid` panic not just when `rhs` is 0, but also when the division overflows. For unsigned numbers, document that `div_euclid` and `rem_euclid` panic when `rhs` is 0.
Plugins deprecation: don’t suggest simply removing the attribute Building Servo with a recent Nightly produces: ```rust warning: use of deprecated attribute `plugin`: compiler plugins are deprecated. See rust-lang#29597 --> components/script/lib.rs:14:1 | 14 | #![plugin(script_plugins)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: remove this attribute | = note: `#[warn(deprecated)]` on by default ``` First, linking to rust-lang#29597 is not ideal since there is pretty much no discussion there of the deprecation and what can be used instead. This PR changes the link to the deprecation PR which does have more discussion. Second, the “remove this attribute” suggestion is rather unhelpful. Just because a feature is deprecated doesn’t mean that simply removing its use without a replacement is acceptable. In the case of custom lint, there is no replacement available. Prefixing a message with “help:” when telling users that they’re screwed honestly feels disrespectful. This PR also changes the message to be more factual.
…r=simulacrum add option to ping llvm ice-breakers to triagebot
reorder fmt docs for more clarity I adjusted these docs in rust-lang#65332 but wasn't happy with the result when seeing it in rustdoc. So this reorders the subsections in the "Formatting Parameters" section to be more logical (subsections that reference `width` come after the `width` subsection) and they also all have examples now.
Update backtrace to 0.3.40 Diff: rust-lang/backtrace-rs@0.3.37...b5cc5b1 Pretty low risk, considering the only changes are in low-tier targets. r? @cramertj cc @alexcrichton
@bors r+ p=13 rollup=never |
📌 Commit 772a8d2 has been approved by |
⌛ Testing commit 772a8d2 with merge cf57b72ec3522283c50fcc81d91e645bc9da88bf... |
#65531 (comment) points out that that PR is likely to fail, so closing this in favor of a rollup without that PR. |
For some reason this is still in the bors queue...? @bors p- rollup- |
@bors ping |
😪 I'm awake I'm awake |
@bors r+ |
📌 Commit 772a8d2 has been approved by |
@bors r- |
Successful merges:
TokenTree
toTokenStream
conversions #65455 (Avoid unnecessaryTokenTree
toTokenStream
conversions)LexicalResolve::expansion()
#65480 (Speed upLexicalResolve::expansion()
)Failed merges:
src/llvm-emscripten
submodule #65501 (Removesrc/llvm-emscripten
submodule)r? @ghost