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.
1 parent 3e29fe3 commit cf4ab38Copy full SHA for cf4ab38
src/lib.rs
@@ -540,6 +540,7 @@ pub fn format_snippet(snippet: &str, config: &Config) -> Option<String> {
540
let input = Input::Text(snippet.into());
541
let mut config = config.clone();
542
config.set().write_mode(config::WriteMode::Plain);
543
+ config.set().hide_parse_errors(true);
544
match format_input(input, &config, Some(&mut out)) {
545
// `format_input()` returns an empty string on parsing error.
546
Ok(..) if out.is_empty() && !snippet.is_empty() => None,
0 commit comments