Skip to content
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 7 pull requests #57755

Merged
merged 20 commits into from Jan 19, 2019

Conversation

Projects
None yet
7 participants
@Centril
Copy link
Contributor

Centril commented Jan 19, 2019

Successful merges:

  • #57486 (Simplify TokenStream some more)
  • #57502 (make trait-aliases work across crates)
  • #57598 (Add missing unpretty option help message)
  • #57649 (privacy: Account for associated existential types)
  • #57659 (Fix release manifest generation)
  • #57699 (add applicability to remaining suggestions)
  • #57719 (Tweak expand_node)

Failed merges:

r? @ghost

nikomatsakis and others added some commits Jan 8, 2019

introduce `trait_def_id` method
Co-Authored-By: Alexander Regueiro <alexreg@me.com>
integrate trait aliases into def-paths / metadata
Co-authored-by: Alexander Regueiro <alexreg@me.com>
new trait alias tests
Co-authored-by: Alexander Regueiro <alexreg@me.com>
Remove `TokenStream::Tree` variant.
`TokenStream::Stream` can represent a token stream containing any number
of token trees. `TokenStream::Tree` is the special case representing a
single token tree. The latter doesn't occur all that often dynamically,
so this commit removes it, which simplifies the code quite a bit.

This change has mixed performance effects.

- The size of `TokenStream` drops from 32 bytes to 8 bytes, and there
  is one less case for all the match statements.

- The conversion of a `TokenTree` to a `TokenStream` now requires two
  allocations, for the creation of a single element Lrc<Vec<_>>. (But a
  subsequent commit in this PR will reduce the main source of such
  conversions.)
Remove `ThinTokenStream`.
`TokenStream` is now almost identical to `ThinTokenStream`. This commit
removes the latter, replacing it with the former.
Make `TokenStream` use `Option`.
Because that's the more typical way of representing an all-or-nothing
type.
Jethro Beekman
Inline `expand_node`.
This requires restructuring things a little so that there is only one
callsite, ensuring that inlinining doesn't cause unnecessary code bloat.

This reduces instruction counts for the `unicode_normalization`
benchmark by up to 4%.
Rollup merge of #57486 - nnethercote:simplify-TokenStream-more, r=pet…
…rochenkov

Simplify `TokenStream` some more

These commits simplify `TokenStream`, remove `ThinTokenStream`, and avoid some clones. The end result is simpler code and a slight perf win on some benchmarks.

r? @petrochenkov
Rollup merge of #57502 - nikomatsakis:fix-trait-alias-1b, r=nikomatsakis
make trait-aliases work across crates

This is rebase of a small part of @alexreg's PR #55994. It focuses just on the changes that integrate trait aliases properly into crate metadata, excluding the stylistic edits and the trait objects.

The stylistic edits I also rebased and can open a separate PR.

The trait object stuff I found challenging and decided it basically needed to be reimplemented. For now I've excluded it.

Since this is really @alexreg's work (I really just rebased) I am going to make it r=me once it is working.

Fixes #56488.
Fixes #57023.
Rollup merge of #57598 - h-michael:unpretty-help, r=oli-obk
Add missing unpretty option help message

There are some missing help messages that is printed `ructc -Zunpretty help` and receiving invalid option.

related with #16419, #45721, #21085, #31916
Rollup merge of #57649 - petrochenkov:privexist, r=arielb1
privacy: Account for associated existential types

Turns out they *can* be associated (but only in impls, not traits).
Fixes #53546 (comment)

r? @arielb1
Rollup merge of #57699 - euclio:applicability-ify, r=petrochenkov
add applicability to remaining suggestions

Fixes #50723.

I noticed that the suggestion methods on `DiagnosticBuilder` weren't actually deprecated due to #57679. This PR deprecates them properly and fixes the remaining usages.

There's also a PR for clippy at rust-lang/rust-clippy#3667.
Rollup merge of #57719 - nnethercote:expand_node-FIDDLING, r=nikomats…
…akis

Tweak `expand_node`

These commits speed up the `unicode_normalization` benchmark a little.
@Centril

This comment has been minimized.

Copy link
Contributor Author

Centril commented Jan 19, 2019

@bors r+ p=7

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Jan 19, 2019

📌 Commit 92fecfb has been approved by Centril

@bors

This comment has been minimized.

Copy link
Contributor

bors commented Jan 19, 2019

⌛️ Testing commit 92fecfb with merge 9323499...

bors added a commit that referenced this pull request Jan 19, 2019

Auto merge of #57755 - Centril:rollup, r=Centril
Rollup of 7 pull requests

Successful merges:

 - #57486 (Simplify `TokenStream` some more)
 - #57502 (make trait-aliases work across crates)
 - #57598 (Add missing unpretty option help message)
 - #57649 (privacy: Account for associated existential types)
 - #57659 (Fix release manifest generation)
 - #57699 (add applicability to remaining suggestions)
 - #57719 (Tweak `expand_node`)

Failed merges:

r? @ghost
@bors

This comment has been minimized.

Copy link
Contributor

bors commented Jan 19, 2019

☀️ Test successful - checks-travis, status-appveyor
Approved by: Centril
Pushing 9323499 to master...

@bors bors merged commit 92fecfb into rust-lang:master Jan 19, 2019

1 check passed

homu Test successful
Details

@Centril Centril deleted the Centril:rollup branch Jan 19, 2019

mikerite added a commit to mikerite/rust-clippy that referenced this pull request Jan 20, 2019

matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Jan 21, 2019

submodules: update clippy from 1b89724b to 1838bfe5
Changes:
````
Fixing typo in CONTRIBUTING.md
Fix breakage due to rust-lang#57651
Run rustfmt
Fixed breakage due to rust-lang#57489
Fix breakage due to rust-lang#57755
Catch up with `format_args` change
Fix bad `while_let_on_iterator` suggestion.
rustup rust-lang#57747
Fixing issues pointed out by dogfood tests.
Update to collect all the files then throw the error.
Adding a test for checking if test files are missing.
Remove bors.toml
add applicability to lint name suggestion
````

VardhanThigle pushed a commit to jethrogb/rust that referenced this pull request Jan 31, 2019

submodules: update clippy from 1b89724b to 1838bfe5
Changes:
````
Fixing typo in CONTRIBUTING.md
Fix breakage due to rust-lang#57651
Run rustfmt
Fixed breakage due to rust-lang#57489
Fix breakage due to rust-lang#57755
Catch up with `format_args` change
Fix bad `while_let_on_iterator` suggestion.
rustup rust-lang#57747
Fixing issues pointed out by dogfood tests.
Update to collect all the files then throw the error.
Adding a test for checking if test files are missing.
Remove bors.toml
add applicability to lint name suggestion
````
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.