Fix clippy warnings in security/manager/ssl/pdf_trust_anchors
Categories
(Developer Infrastructure :: Lint and Formatting, task)
Tracking
(Not tracked)
People
(Reporter: Sylvestre, Unassigned, Mentored)
References
(Blocks 1 open bug)
Details
(Keywords: good-first-bug, Whiteboard: [lang=rust])
Filing as a good first bug to learn workflows.
The crate in security/manager/ssl/pdf_trust_anchors triggers clippy warnings from the default lint set. Fix them all in a single patch; each one is a small, mechanical change and clippy's output suggests the fix.
Warnings and links to the code:
security/manager/ssl/pdf_trust_anchors/src/lib.rs:10:36: this lifetime isn't used in the function definition [clippy::extra_unused_lifetimes]
https://searchfox.org/firefox-main/rev/cac2c0cf44beecb92c93119bd79e2408636f76d7/security/manager/ssl/pdf_trust_anchors/src/lib.rs#10
security/manager/ssl/pdf_trust_anchors/src/lib.rs:14:74: this expression creates a reference which is immediately dereferenced by the compiler [clippy::needless_borrow]
https://searchfox.org/firefox-main/rev/cac2c0cf44beecb92c93119bd79e2408636f76d7/security/manager/ssl/pdf_trust_anchors/src/lib.rs#14
To verify the fix:
./mach lint -W -l clippy security/manager/ssl/pdf_trust_anchors
The warnings above should no longer be reported, and the code should still build (./mach build).
Tutorial to contribute:
https://firefox-source-docs.mozilla.org/contributing/contribution_quickref.html
https://firefox-source-docs.mozilla.org/contributing/stack_quickref.html
Please don't ask for the bug to be assigned. It will be automatically assigned to the first patch.
Description
•