- 
                Notifications
    You must be signed in to change notification settings 
- Fork 13.9k
rustdoc: skip #[allow(missing docs)] for docs in coverage report #76196
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 pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @jyn514 (or someone else) soon. If any changes to this PR are deemed necessary, please add them as extra commits. This ensures that the reviewer can see what has changed since they last reviewed the code. Due to the way GitHub handles out-of-date commits, this should also make it reasonably obvious what issues have or haven't been addressed. Large or tricky changes may require several passes of review and changes. Please see the contribution instructions for more information. | 
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.
Right now I'm not sure how this can be tested (CI)? (I verified it by hand and ran the unit tests)
You can test it by adding a file to src/test/rustdoc-ui/coverage/ that uses doc(hidden). Not sure how to generate the .stdout files, maybe run x.py test src/test/rustdoc-ui/coverage/ --bless?
34a576d    to
    1375fcb      
    Compare
  
    | 
 @jyn514 thanks for the help and the suggestions! I'll take a look and ping you when I'm done 👍 | 
1375fcb    to
    3fc8ae6      
    Compare
  
    cd5eec7    to
    81f65a8      
    Compare
  
    | 
 #![deny(missing_docs)]
//! crate docs
#[allow(missing_docs)]
pub mod foo {
    pub struct Foo;
} | 
81f65a8    to
    3a49711      
    Compare
  
    | @ollie27 thanks for the input! That was indeed a part that I missed, but it's covered now 👍 | 
| @r-52 Ping from triage, would you mind address the review comments above? thanks! | 
| @crlf0710 hi, thanks the ping! Right now, I don't have the time to work on it. Feel free to pick it up | 
| I'll finish it then. | 
3a49711    to
    5969b38      
    Compare
  
    | Ok, updated! | 
During the document coverage reporting with ```bash rustdoc something.rs -Z unstable-options --show-coverage ``` the coverage report also includes parts of the code that are marked with `#[allow(missing_docs)]`, which outputs lower numbers in the coverage report even though these parts should be ignored for the calculation. Co-authored-by: Joshua Nelson <joshua@yottadb.com>
5969b38    to
    6854440      
    Compare
  
    | @bors r+ Looks great! | 
| 📌 Commit 6854440 has been approved by  | 
… r=jyn514 rustdoc: skip #[allow(missing docs)] for docs in coverage report During the document coverage reporting with: ```bash rustdoc something.rs -Z unstable-options --show-coverage ``` the coverage report counts code that is marked with `#[allow(missing_docs)]` for the calculation, which outputs lower numbers in the coverage report even though these parts should be ignored for the calculation. Right now I'm not sure how this can be tested (CI)? (I verified it by hand and ran the unit tests) r? @jyn514 **Reference:** Fixes rust-lang#76121
| ☀️ Test successful - checks-actions, checks-azure | 
During the document coverage reporting with:
the coverage report counts code that is marked with
#[allow(missing_docs)]for the calculation, which outputs lower numbers in the coverage report even though these parts should be ignored for the calculation.Right now I'm not sure how this can be tested (CI)? (I verified it by hand and ran the unit tests)
r? @jyn514
Reference: Fixes #76121