]> git.lizzy.rs Git - rust.git/blobdiff - clippy_lints/src/write.rs
Auto merge of #9148 - arieluy:then_some_unwrap_or, r=Jarcho
[rust.git] / clippy_lints / src / write.rs
index 67b2bc8c3f3cd86e823868a0475f083ea535f659..08b8894752011c86a51f8ea36aa15eba82a19cd8 100644 (file)
@@ -515,7 +515,7 @@ fn parse_fmt_string(&self, cx: &EarlyContext<'_>, str_lit: &StrLit) -> Option<Si
             args.push(arg, span);
         }
 
-        parser.errors.is_empty().then(move || args)
+        parser.errors.is_empty().then_some(args)
     }
 
     /// Checks the arguments of `print[ln]!` and `write[ln]!` calls. It will return a tuple of two