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.
needless_return
1 parent b885035 commit 678dcddCopy full SHA for 678dcdd
clippy_lints/src/methods/option_map_or_none.rs
@@ -97,7 +97,7 @@ pub(super) fn check<'tcx>(
97
let func_snippet = snippet(cx, map_arg.span, "..");
98
let msg = "called `map_or(None, ..)` on an `Option` value. This can be done more directly by calling \
99
`and_then(..)` instead";
100
- return span_lint_and_sugg(
+ span_lint_and_sugg(
101
cx,
102
OPTION_MAP_OR_NONE,
103
expr.span,
@@ -110,7 +110,7 @@ pub(super) fn check<'tcx>(
110
let msg = "called `map_or(None, Some)` on a `Result` value. This can be done more directly by calling \
111
`ok()` instead";
112
let self_snippet = snippet(cx, recv.span, "..");
113
114
115
RESULT_MAP_OR_INTO_OPTION,
116
0 commit comments