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

Force token collection to run when parsing nonterminals #81177

Merged
merged 1 commit into from Jan 22, 2021

Conversation

Aaron1011
Copy link
Member

Fixes #81007

Previously, we would fail to collect tokens in the proper place when
only builtin attributes were present. As a result, we would end up with
attribute tokens in the collected TokenStream, leading to duplication
when we attempted to prepend the attributes from the AST node.

We now explicitly track when token collection must be performed due to
nomterminal parsing.

@rust-highfive
Copy link
Collaborator

r? @estebank

(rust-highfive has picked a reviewer for you, use r? to override)

@rust-highfive rust-highfive added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Jan 18, 2021
@Aaron1011
Copy link
Member Author

r? @petrochenkov

@Aaron1011
Copy link
Member Author

@bors try @rust-timer queue

@rust-timer
Copy link
Collaborator

Awaiting bors try build completion.

@bors
Copy link
Contributor

bors commented Jan 18, 2021

⌛ Trying commit 63029c0da16ceb7c3f3b3234843144507eb584cb with merge 56b25a6a8cfe3ac5ad688f533bd0745e4436acd0...

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@rust-log-analyzer

This comment has been minimized.

@Aaron1011
Copy link
Member Author

@petrochenkov This is now ready for review

@petrochenkov
Copy link
Contributor

Could you turn force_collect into enum as estebank asks?
r=me after doing that and squashing commits.

@petrochenkov petrochenkov added S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. and removed S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 20, 2021
Fixes rust-lang#81007

Previously, we would fail to collect tokens in the proper place when
only builtin attributes were present. As a result, we would end up with
attribute tokens in the collected `TokenStream`, leading to duplication
when we attempted to prepend the attributes from the AST node.

We now explicitly track when token collection must be performed due to
nomterminal parsing.
@Aaron1011
Copy link
Member Author

@bors r=petrochenkov

@bors
Copy link
Contributor

bors commented Jan 20, 2021

📌 Commit 11b1e37 has been approved by petrochenkov

@bors
Copy link
Contributor

bors commented Jan 20, 2021

🌲 The tree is currently closed for pull requests below priority 1000. This pull request will be tested once the tree is reopened.

@bors bors added S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. and removed S-waiting-on-author Status: This is awaiting some action (such as code changes or more information) from the author. labels Jan 20, 2021
@bors
Copy link
Contributor

bors commented Jan 22, 2021

⌛ Testing commit 11b1e37 with merge dc1eee2...

@bors
Copy link
Contributor

bors commented Jan 22, 2021

☀️ Test successful - checks-actions
Approved by: petrochenkov
Pushing dc1eee2 to master...

@bors bors added the merged-by-bors This PR was explicitly merged by bors. label Jan 22, 2021
@bors bors merged commit dc1eee2 into rust-lang:master Jan 22, 2021
@rustbot rustbot added this to the 1.51.0 milestone Jan 22, 2021
Xiretza added a commit to Xiretza/rust that referenced this pull request Aug 17, 2022
…recovery

Something seems to have gotten out of sync during the creation of rust-lang#81177,
where both the argument and comment were introduced.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Aug 17, 2022
…docs, r=davidtwco

Fix documentation of rustc_parse::parser::Parser::parse_stmt_without_recovery

Something seems to have gotten out of sync during the creation of rust-lang#81177, where both the argument and comment were introduced.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Aug 17, 2022
…docs, r=davidtwco

Fix documentation of rustc_parse::parser::Parser::parse_stmt_without_recovery

Something seems to have gotten out of sync during the creation of rust-lang#81177, where both the argument and comment were introduced.
matthiaskrgr added a commit to matthiaskrgr/rust that referenced this pull request Aug 18, 2022
…docs, r=davidtwco

Fix documentation of rustc_parse::parser::Parser::parse_stmt_without_recovery

Something seems to have gotten out of sync during the creation of rust-lang#81177, where both the argument and comment were introduced.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merged-by-bors This PR was explicitly merged by bors. S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion.
Projects
None yet
8 participants