We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
map_unwrap_or
1 parent 90ec92f commit 48b8dd9Copy full SHA for 48b8dd9
clippy_lints/src/derivable_impls.rs
@@ -105,6 +105,7 @@ fn check_struct<'tcx>(
105
if let TyKind::Path(QPath::Resolved(_, p)) = self_ty.kind
106
&& let Some(PathSegment { args, .. }) = p.segments.last()
107
{
108
+ #[expect(clippy::map_unwrap_or)]
109
let args = args.map(|a| a.args).unwrap_or(&[]);
110
111
// ty_args contains the generic parameters of the type declaration, while args contains the
0 commit comments