mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-11-10 07:04:22 +00:00
Add comment about false positive clippy lint
This commit is contained in:
parent
1fdf3063d0
commit
4087dcf1db
1 changed files with 1 additions and 0 deletions
|
@ -252,6 +252,7 @@ where
|
|||
{
|
||||
/// Ensures a value is in the entry by inserting the default value if empty, and returns a mutable reference
|
||||
/// to the value in the entry.
|
||||
// BUG this clippy lint is a false positive
|
||||
#[allow(clippy::unwrap_or_default)]
|
||||
pub fn or_default(self) -> &'a mut V {
|
||||
self.or_insert_with(Default::default)
|
||||
|
|
Loading…
Reference in a new issue