Uh oh!
There was an error while loading. Please reload this page.
libsyntax: miscellaneous cleanup - #33943
Merged
Merged
Conversation
jseyfried
commented
May 29, 2016
ContributorAuthor
cc @Manishearth |
nrc
commented
May 30, 2016
Member
r=me, could probably land early doesn't look like it will break much, but I guess we may as well wait for a batch if there is no urgency. cc @cgswords |
Manishearth
commented
May 30, 2016
Member
This probably will break aster. |
jseyfriedforce-pushed
the
libsyntax_cleanup
branch
5 times, most recently
from
June 4, 2016 10:00
463955a to
366b01dComparejseyfriedforce-pushed
the
libsyntax_cleanup
branch
4 times, most recently
from
June 12, 2016 12:04
68ab0c8 to
6e7d690Comparebors
commented
Jun 14, 2016
Collaborator
☔ The latest upstream changes (presumably #33749) made this pull request unmergeable. Please resolve the merge conflicts. |
…hod of trait `HasAttrs`.
jseyfriedforce-pushed
the
libsyntax_cleanup
branch
from
June 14, 2016 07:40
6e7d690 to
0644abaCompare| let (body, opt_ident) = expand_loop_block(body, opt_ident, fld); | ||
| fld.cx.expr(expr.span, ast::ExprKind::While(cond, body, opt_ident)) | ||
| .with_attrs(fold_thin_attrs(expr.attrs, fld)) | ||
| expr.node = ast::ExprKind::While(cond, body, opt_ident); |
ContributorAuthor
There was a problem hiding this comment.
fold_thin_attrs became the identity after this commit.
jseyfried
commented
Jun 16, 2016
ContributorAuthor
Rebased and added 3 new commits (r? @nrc) |
nrc
commented
Jun 16, 2016
Member
r=me |
bors
commented
Jun 25, 2016
Collaborator
☔ The latest upstream changes (presumably #34464) made this pull request unmergeable. Please resolve the merge conflicts. |
jseyfried added a commit
to jseyfried/rust
that referenced
this pull request
Jun 26, 2016
Miscellaneous low priority cleanup in `libsyntax`.
bors added a commit
that referenced
this pull request
Jun 26, 2016
Batch up libsyntax breaking changes Batch of the following syntax-[breaking-change] changes: - #34213: Add a variant `Macro` to `TraitItemKind` - #34368: Merge the variant `QPath` of `PatKind` into the variant `PatKind::Path` - #34385: Move `syntax::ast::TokenTree` into a new module `syntax::tokenstream` - #33943: - Remove the type parameter from `visit::Visitor` - Remove `attr::WithAttrs` -- use `attr::HasAttrs` instead. - Change `fold_tt`/`fold_tts` to take token trees by value and avoid wrapping token trees in `Rc`. - Remove the field `ctxt` of `ast::Mac_` - Remove inherent method `attrs()` of types -- use the method `attrs` of `HasAttrs` instead. - #34316: - Remove `ast::Decl`/`ast::DeclKind` and add variants `Local` and `Item` to `StmtKind`. - Move the node id for statements from the `StmtKind` variants to a field of `Stmt` (making `Stmt` a struct instead of an alias for `Spanned<StmtKind>`) - Rename `ast::ExprKind::Again` to `Continue`. - #34339: Generalize and abstract `ThinAttributes` to `ThinVec<Attribute>` - Use `.into()` in convert between `Vec<Attribute>` and `ThinVec<Attribute>` - Use autoderef instead of `.as_attr_slice()` - #34436: Remove the optional expression from `ast::Block` and instead use a `StmtKind::Expr` at the end of the statement list. - #34403: Move errors into a separate crate (unlikely to cause breakage)
bors added a commit
that referenced
this pull request
Jun 27, 2016
Batch up libsyntax breaking changes Batch of the following syntax-[breaking-change] changes: - #34213: Add a variant `Macro` to `TraitItemKind` - #34368: Merge the variant `QPath` of `PatKind` into the variant `PatKind::Path` - #34385: Move `syntax::ast::TokenTree` into a new module `syntax::tokenstream` - #33943: - Remove the type parameter from `visit::Visitor` - Remove `attr::WithAttrs` -- use `attr::HasAttrs` instead. - Change `fold_tt`/`fold_tts` to take token trees by value and avoid wrapping token trees in `Rc`. - Remove the field `ctxt` of `ast::Mac_` - Remove inherent method `attrs()` of types -- use the method `attrs` of `HasAttrs` instead. - #34316: - Remove `ast::Decl`/`ast::DeclKind` and add variants `Local` and `Item` to `StmtKind`. - Move the node id for statements from the `StmtKind` variants to a field of `Stmt` (making `Stmt` a struct instead of an alias for `Spanned<StmtKind>`) - Rename `ast::ExprKind::Again` to `Continue`. - #34339: Generalize and abstract `ThinAttributes` to `ThinVec<Attribute>` - Use `.into()` in convert between `Vec<Attribute>` and `ThinVec<Attribute>` - Use autoderef instead of `.as_attr_slice()` - #34436: Remove the optional expression from `ast::Block` and instead use a `StmtKind::Expr` at the end of the statement list. - #34403: Move errors into a separate crate (unlikely to cause breakage)
bors added a commit
that referenced
this pull request
Jul 6, 2016
Fix expansion performance regression **syntax-[breaking-change] cc #31645** This fixes#34630 by reverting commit 5bf7970 of PR #33943, which landed in #34424. By removing the `Rc<_>` wrapping around `Delimited` and `SequenceRepetition` in `TokenTree`, 5bf7970 made cloning `TokenTree`s more expensive. While this had no measurable performance impact on the compiler's crates, it caused an order of magnitude performance regression on some macro-heavy code in the wild. I believe this is due to clones of `TokenTree`s in `macro_parser.rs` and/or `macro_rules.rs`. r? @nrc
bors added a commit
that referenced
this pull request
Jul 7, 2016
Fix expansion performance regression **syntax-[breaking-change] cc #31645** This fixes#34630 by reverting commit 5bf7970 of PR #33943, which landed in #34424. By removing the `Rc<_>` wrapping around `Delimited` and `SequenceRepetition` in `TokenTree`, 5bf7970 made cloning `TokenTree`s more expensive. While this had no measurable performance impact on the compiler's crates, it caused an order of magnitude performance regression on some macro-heavy code in the wild. I believe this is due to clones of `TokenTree`s in `macro_parser.rs` and/or `macro_rules.rs`. r? @nrc
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for freeto join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
syntax-[breaking-change] cc #31645
Miscellaneous low priority cleanup in
libsyntaxfor the next breaking batch.r? @nrc