-
Notifications
You must be signed in to change notification settings - Fork 12.9k
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
ast: Fix naming conventions in AST structures #90671
Conversation
TraitKind -> Trait TyAliasKind -> TyAlias ImplKind -> Impl FnKind -> Fn All `*Kind`s in AST are supposed to be enums. Tuple structs are converted to braced structs for the types above, and fields are reordered in syntactic order. Also, mutable AST visitor now correctly visit spans in defaultness, unsafety, impl polarity and constness.
Some changes occurred in src/tools/rustfmt. Some changes occurred in src/tools/clippy. cc @rust-lang/clippy |
r? @wesleywiser (rust-highfive has picked a reviewer for you, use r? to override) |
r=me with CI green |
I was planning on doing a subtree sync when I saw this. I've recently done a decent amount of refactoring of the impacted code on the rustfmt side which is likely to cause some hefty merge conflicts. Would be good to give bors a high priority on this one to get it landed more quickly since dealing with merge conflicts during subtree syncs is a bit of a pain |
📌 Commit 2834f57 has been approved by |
☀️ Test successful - checks-actions |
Finished benchmarking commit (68568dc): comparison url. Summary: This benchmark run did not return any relevant changes. If you disagree with this performance assessment, please file an issue in rust-lang/rustc-perf. @rustbot label: -perf-regression |
TraitKind -> Trait
TyAliasKind -> TyAlias
ImplKind -> Impl
FnKind -> Fn
All
*Kind
s in AST are supposed to be enums.Tuple structs are converted to braced structs for the types above, and fields are reordered in syntactic order.
Also, mutable AST visitor now correctly visit spans in defaultness, unsafety, impl polarity and constness.
Noticed when reviewing #90076.