Skip to content

Commit 925c1c4

Browse files
committed
[Clippy] Swap filter_map_bool_then to use diagnostic item instead of path
1 parent 7bc30a7 commit 925c1c4

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

core/src/bool.rs

+1
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,7 @@ impl bool {
5555
/// assert_eq!(a, 1);
5656
/// ```
5757
#[stable(feature = "lazy_bool_to_option", since = "1.50.0")]
58+
#[cfg_attr(not(test), rustc_diagnostic_item = "bool_then")]
5859
#[inline]
5960
pub fn then<T, F: FnOnce() -> T>(self, f: F) -> Option<T> {
6061
if self { Some(f()) } else { None }

0 commit comments

Comments
 (0)