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

Perform cfg attribute processing on decorator-generated items #34295

Merged
merged 2 commits into from
Jun 19, 2016

Conversation

jseyfried
Copy link
Contributor

@@ -787,8 +787,6 @@ fn decorate(a: Annotatable, fld: &mut MacroExpander) -> SmallVector<Annotatable>
let mut decorator_items = SmallVector::zero();
let mut new_attrs = Vec::new();
expand_decorators(a.clone(), fld, &mut decorator_items, &mut new_attrs);
let decorator_items =
decorator_items.into_iter().flat_map(|a| expand_annotatable(a, fld)).collect();
Copy link
Contributor Author

@jseyfried jseyfried Jun 16, 2016

Choose a reason for hiding this comment

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

decorator_items are already expanded in expand_decorators().
I mistakenly added this in #34010. Since expansion is idempotent, it didn't cause bugs, just regressed expansion performance.

@jseyfried
Copy link
Contributor Author

cc @eddyb @LeoTestard

@jseyfried
Copy link
Contributor Author

ping @nrc or @eddyb -- it'd be nice to land this ASAP.

@eddyb
Copy link
Member

eddyb commented Jun 19, 2016

@bors r+

@bors
Copy link
Contributor

bors commented Jun 19, 2016

📌 Commit c41cf30 has been approved by eddyb

@jseyfried
Copy link
Contributor Author

@eddyb Thanks!

@bors
Copy link
Contributor

bors commented Jun 19, 2016

⌛ Testing commit c41cf30 with merge b1ae194...

bors added a commit that referenced this pull request Jun 19, 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.

4 participants