-
Notifications
You must be signed in to change notification settings - Fork 563
Add a section about rustc_clean
#2670
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
Conversation
|
Thanks for the PR. If you have write access, feel free to merge this PR if it does not need reviews. You can request a review using |
|
This is a mix from what I learned about the attribute from my first time interacting with it today, and copy pasting from some doc-comments in the rustc source code. r? rustc-dev-guide |
4701fa2 to
ba22e06
Compare
jyn514
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nice, thanks! r=me with or without fixing the nits.
| * `cfg="<cond>"` — checks the cfg condition `<cond>`, and only runs the check if the config condition evaluates to true. | ||
| This can be used to only run the `rustc_clean` attribute in a specific revision. | ||
| * `except="<query1>,<query2>,..."` — asserts that the query results for the listed queries must be different, | ||
| rather than the same. | ||
| * `loaded_from_disk="<query1>,<query2>,..."` — asserts that the query results for the listed queries |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
could you also add a bullet about label?
if it's not too much trouble, it would be nice to update the template at https://github.com/rust-lang/rust/blob/646a3f8c15baefb98dc6e0c1c1ba3356db702d2a/compiler/rustc_feature/src/builtin_attrs.rs#L1493 as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Hmmm I've looked at the source code in dirty_clean.rs for a few minutes but I don't fully understand how they work. I don't want to explain it incorrectly so I'll leave this one for someone else to add
|
it also occurs to me that this is a port of the comment in |
ba22e06 to
83f54db
Compare
No description provided.