Skip to content

Commit

Permalink
Auto merge of #133830 - compiler-errors:span-key, r=lcnr
Browse files Browse the repository at this point in the history
Rework dyn trait lowering to stop being so intertwined with trait alias expansion

This PR reworks the trait object lowering code to stop handling trait aliases so funky, and removes the `TraitAliasExpander` in favor of a much simpler design. This refactoring is important for making the code that I'm writing in rust-lang/rust#133397 understandable and easy to maintain, so the diagnostics regressions are IMO inevitable.

In the old trait object lowering code, we used to be a bit sloppy with the lists of traits in their unexpanded and expanded forms. This PR largely rewrites this logic to expand the trait aliases *once* and handle them more responsibly throughout afterwards.

Please review this with whitespace disabled.

r? lcnr
  • Loading branch information
bors committed Jan 21, 2025
2 parents c955fae + b4d22c4 commit dfb8d32
Showing 0 changed files with 0 additions and 0 deletions.

0 comments on commit dfb8d32

Please sign in to comment.