Skip to content

Conversation

@Zalathar
Copy link
Member

While working towards #21043, I found myself wanting to be able to see more information about macros in snapshot tests that use DefMap dumps.

This PR therefore makes a few changes to the dump output:

  • Make the dump output nicer to read (at least to my eyes) by using bulleted lists, making sure names are surrounded by space on both sides, using full words to indicate namespace and import style, and adding parens around (block scope).
  • When dumping macros, also indicate which macro sub-namespace they belong to (function-like ! or attribute/derive #).
  • When dumping scopes, also dump any legacy-textual-scope macros visible at the end of the scope, marked with a (legacy) prefix.

@rustbot rustbot added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 22, 2025
Copy link
Member

@Veykril Veykril left a comment

Choose a reason for hiding this comment

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

Thanks!

@Veykril Veykril added this pull request to the merge queue Nov 22, 2025
Merged via the queue into rust-lang:master with commit 9e833ab Nov 22, 2025
15 checks passed
@rustbot rustbot removed the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. label Nov 22, 2025
@Zalathar Zalathar deleted the dump branch November 22, 2025 23:08
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.

3 participants