Skip to content

Conversation

nnethercote
Copy link
Contributor

Minor improvements I found while looking at this code. Best reviewed one commit at a time.

r? @BoxyUwU

It's always equal to `ast::AttrVec`, so just use that directly.
It's a "utility trait to reduce boilerplate" implemented for `P` and
`AstNodeWrapper`, but removing it gives a net reduction of twenty lines
of code. It's also simpler to just implement
`HasNodeId`/`HasAttrs`/`HasTokens` directly on types instead of via
`AstDeref`.

(I decided to make this change when doing some related refactoring and
the error messages involving `AstDeref` and `HasAttrs` were hard to
understand; removing it helped a lot.)
@rustbot rustbot added S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue. labels May 9, 2025
@compiler-errors
Copy link
Member

r? compiler-errors @bors r+ rollup

@bors
Copy link
Collaborator

bors commented May 10, 2025

📌 Commit 5ebcbfc has been approved by compiler-errors

It is now in the queue for this repository.

@rustbot rustbot assigned compiler-errors and unassigned BoxyUwU May 10, 2025
@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-review Status: Awaiting review from the assignee but also interested parties. labels May 10, 2025
bors added a commit to rust-lang-ci/rust that referenced this pull request May 11, 2025
Rollup of 7 pull requests

Successful merges:

 - rust-lang#140792 (Use intrinsics for `{f16,f32,f64,f128}::{minimum,maximum}` operations)
 - rust-lang#140795 (Prefer to suggest stable candidates rather than unstable ones)
 - rust-lang#140865 (Make t letter looks like lowercase rather than uppercase)
 - rust-lang#140878 (Two expand-related cleanups)
 - rust-lang#140882 (Split duration_constructors to get non-controversial constructors out)
 - rust-lang#140886 (Update deps of bootstrap for Cygwin)
 - rust-lang#140903 (test intrinsic fallback bodies with Miri)

r? `@ghost`
`@rustbot` modify labels: rollup
@bors bors merged commit f9fdf40 into rust-lang:master May 11, 2025
6 checks passed
@rustbot rustbot added this to the 1.89.0 milestone May 11, 2025
rust-timer added a commit to rust-lang-ci/rust that referenced this pull request May 11, 2025
Rollup merge of rust-lang#140878 - nnethercote:two-expand-cleanups, r=compiler-errors

Two expand-related cleanups

Minor improvements I found while looking at this code. Best reviewed one commit at a time.

r? `@BoxyUwU`
@nnethercote nnethercote deleted the two-expand-cleanups branch May 14, 2025 06:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-bors Status: Waiting on bors to run and complete tests. Bors will change the label on completion. T-compiler Relevant to the compiler team, which will review and decide on the PR/issue.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants