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

Fix a regression in the configuration folder #34031

Merged
merged 2 commits into from
Jun 5, 2016

Conversation

jseyfried
Copy link
Contributor

@jseyfried jseyfried commented Jun 2, 2016

This fixes #34028, a regression caused by #33706 in which unconfigured impl items generated by a macro in an impl item position are not removed.
r? @nrc

@jseyfried jseyfried changed the title Fix a bug in the configuration folder Fix a regression in the configuration folder Jun 2, 2016
@@ -242,7 +234,17 @@ impl<T: CfgFolder> fold::Folder for T {
}

fn fold_item(&mut self, item: P<ast::Item>) -> SmallVector<P<ast::Item>> {
self.configure(item).map(|item| SmallVector::one(item.map(|i| self.fold_item_simple(i))))
self.configure(item).map(|item| fold::noop_fold_item(item, self))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a pure uninlining refactoring -- c.f. noop_fold_item.

@jseyfried
Copy link
Contributor Author

It would be nice to land this ASAP (cc @alexcrichton or @eddyb -- r?)

@eddyb
Copy link
Member

eddyb commented Jun 4, 2016

@bors r+

@bors
Copy link
Contributor

bors commented Jun 4, 2016

📌 Commit 9639ec8 has been approved by eddyb

@bors
Copy link
Contributor

bors commented Jun 4, 2016

⌛ Testing commit 9639ec8 with merge ccfaaa7...

bors added a commit that referenced this pull request Jun 4, 2016
Fix a regression in the configuration folder

This fixes #34028, a regression caused by #33706 in which unconfigured impl items generated by a macro in an impl item position are not removed.
r? @nrc
@jseyfried
Copy link
Contributor Author

@eddyb Thanks!

@bors
Copy link
Contributor

bors commented Jun 5, 2016

💔 Test failed - auto-mac-32-opt

@jseyfried
Copy link
Contributor Author

@bors retry

@bors bors merged commit 9639ec8 into rust-lang:master Jun 5, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Macro hygiene regression
4 participants