There was an error while loading. Please reload this page.
1 parent 576fba8 commit 8a3bce0Copy full SHA for 8a3bce0
parser/src/parse.rs
@@ -1425,8 +1425,8 @@ impl Parser<'_> {
1425
Ok(n) => n.to_string(),
1426
Err(_) => s.into(),
1427
};
1428
- if s.contains('`') {
1429
- s = s.replace('`', "¯");
+ if s.contains(['`', '-']) {
+ s = s.replace(['`', '-'], "¯");
1430
}
1431
(r, s, Some(span))
1432
} else if let Some(((n, s), span)) = self.infinity().map(Into::into) {
src/format.rs
@@ -2044,12 +2044,14 @@ F,1
2044
\\\\25cb
2045
⊗
2046
˜⊗
2047
+`5
2048
";
2049
let output = "\
2050
F₁
2051
○
2052
˜⨂
2053
⨂
2054
+¯5
2055
2056
let formatted = format_str(input, &FormatConfig::default()).unwrap().output;
2057
assert_eq!(formatted, output);
0 commit comments