From 3882816712d625bbfa8fc0375719fb7454f55efb Mon Sep 17 00:00:00 2001 From: Josh Triplett Date: Tue, 28 Oct 2025 07:41:44 -0700 Subject: [PATCH] fix: Use vertical ellipsis for elision, rather than double-dagger MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The Unicode renderer used "‡", the double-dagger symbol, to ellipsize the vertical bar to indicate elided lines. Use a vertical ellipsis instead. --- examples/expected_type.svg | 2 +- examples/struct_name_as_context.svg | 2 +- src/renderer/render.rs | 2 +- .../color/fold_ann_multiline.unicode.term.svg | 2 +- ...ght_duplicated_diff_lines.unicode.term.svg | 2 +- tests/color/highlight_source.unicode.term.svg | 2 +- tests/color/issue_9.unicode.term.svg | 2 +- ...iple_highlight_duplicated.unicode.term.svg | 2 +- tests/formatter.rs | 12 +++++----- tests/rustc_tests.rs | 22 +++++++++---------- 10 files changed, 25 insertions(+), 25 deletions(-) diff --git a/examples/expected_type.svg b/examples/expected_type.svg index b88bc22e..3a5ce9e1 100644 --- a/examples/expected_type.svg +++ b/examples/expected_type.svg @@ -29,7 +29,7 @@ ──────────────── while parsing this struct - + 29 range: <22, 25>, diff --git a/examples/struct_name_as_context.svg b/examples/struct_name_as_context.svg index 8573af31..fd8b381c 100644 --- a/examples/struct_name_as_context.svg +++ b/examples/struct_name_as_context.svg @@ -27,7 +27,7 @@ 1 struct S { - + 6 fn foo() {}, diff --git a/src/renderer/render.rs b/src/renderer/render.rs index 939ae753..6a6cab83 100644 --- a/src/renderer/render.rs +++ b/src/renderer/render.rs @@ -2229,7 +2229,7 @@ fn draw_note_separator( fn draw_line_separator(renderer: &Renderer, buffer: &mut StyledBuffer, line: usize, col: usize) { let (column, dots) = match renderer.decor_style { DecorStyle::Ascii => (0, "..."), - DecorStyle::Unicode => (col - 2, "‡"), + DecorStyle::Unicode => (col - 2, "⋮"), }; buffer.puts(line, column, dots, ElementStyle::LineNumber); } diff --git a/tests/color/fold_ann_multiline.unicode.term.svg b/tests/color/fold_ann_multiline.unicode.term.svg index 92dea608..6d45d9a8 100644 --- a/tests/color/fold_ann_multiline.unicode.term.svg +++ b/tests/color/fold_ann_multiline.unicode.term.svg @@ -37,7 +37,7 @@ 55 (Some(start), Some(end)) if start > end_index || end < start_index => continue, - + 72 } diff --git a/tests/color/highlight_duplicated_diff_lines.unicode.term.svg b/tests/color/highlight_duplicated_diff_lines.unicode.term.svg index 5ae70d1a..0be45f93 100644 --- a/tests/color/highlight_duplicated_diff_lines.unicode.term.svg +++ b/tests/color/highlight_duplicated_diff_lines.unicode.term.svg @@ -31,7 +31,7 @@ ━━━━━━━━━━━━ - + 24 String::from(""), diff --git a/tests/color/highlight_source.unicode.term.svg b/tests/color/highlight_source.unicode.term.svg index 9ab809cc..8498b6ec 100644 --- a/tests/color/highlight_source.unicode.term.svg +++ b/tests/color/highlight_source.unicode.term.svg @@ -27,7 +27,7 @@ 2 [workspace.lints.rust] - + 9 unused_qualifications = "warn" diff --git a/tests/color/issue_9.unicode.term.svg b/tests/color/issue_9.unicode.term.svg index b870c160..b4e9e9e4 100644 --- a/tests/color/issue_9.unicode.term.svg +++ b/tests/color/issue_9.unicode.term.svg @@ -29,7 +29,7 @@ move occurs because `x` has type `std::vec::Vec<i32>`, which does not implement the `Copy` trait - + 7 let y = x; diff --git a/tests/color/multiple_highlight_duplicated.unicode.term.svg b/tests/color/multiple_highlight_duplicated.unicode.term.svg index 8bcafa2a..34d8e5d7 100644 --- a/tests/color/multiple_highlight_duplicated.unicode.term.svg +++ b/tests/color/multiple_highlight_duplicated.unicode.term.svg @@ -31,7 +31,7 @@ ━━━━━━━━━━━━ - + 24 String::from(""), diff --git a/tests/formatter.rs b/tests/formatter.rs index 99a08636..d456471f 100644 --- a/tests/formatter.rs +++ b/tests/formatter.rs @@ -1700,7 +1700,7 @@ error[E0599]: no method named `pick` found for struct `Chaenomeles` in the curre ╭▸ LL │ pub struct Chaenomeles; │ ────────────────────── method `pick` not found for this struct - ‡ + ⋮ LL │ banana::Chaenomeles.pick() │ ━━━━ method not found in `Chaenomeles` ╰╴ @@ -2487,7 +2487,7 @@ LL │ ┏ Box::new( LL │ ┃ Ok::<_, ()>( LL │ ┃ Err::<(), _>( LL │ ┃ Ok::<_, ()>( - ‡ ┃ + ⋮ ┃ LL │ ┃ ) │ ┗━━━━━┛ type mismatch resolving `, ...>>, ...> as Future>::Error == Foo` ╰╴ @@ -2600,7 +2600,7 @@ LL │ ┏ Box::new( LL │ ┃ Ok::<_, ()>( LL │ ┃ Err::<(), _>( LL │ ┃ Ok::<_, ()>( - ‡ ┃ + ⋮ ┃ LL │ ┃ ) │ ┗━━━━━┛ type mismatch resolving `, ...>>, ...> as Future>::Error == Foo` ╰╴ @@ -2785,7 +2785,7 @@ LL │ let x: Atype< LL │ │ Btype< LL │ │ Ctype< LL │ │ Atype< - ‡ │ + ⋮ │ LL │ │ i32 LL │ │ > = Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(Ok(O… │ │┏━━━━━│━━━┛ @@ -4309,7 +4309,7 @@ error[E0277]: the size for values of type `T` cannot be known at compilation tim ╭▸ 12 │ cargo │ ━━━━━ - ‡ + ⋮ 18 │ zappy ╰╴ "#]]; @@ -4800,7 +4800,7 @@ error: consider adding a `;` to the last statement for consistent formatting 5 │ ┃ if *x > 0 { 6 │ ┃ println!("Positive number"); 7 │ ┃ } else { - ‡ ┃ + ⋮ ┃ 10 │ ┃ }) │ ┗━━━━━━┛ ╰╴ diff --git a/tests/rustc_tests.rs b/tests/rustc_tests.rs index 4990a05b..3497b269 100644 --- a/tests/rustc_tests.rs +++ b/tests/rustc_tests.rs @@ -77,7 +77,7 @@ error: foo │ 2 │ fn foo() { │ ┏━━━━━━━━━━┛ - ‡ ┃ + ⋮ ┃ 5 │ ┃ } ╰╴┗━━━┛ test "#]]; @@ -1029,7 +1029,7 @@ error: foo 5 │ │ 1 6 │ │ 2 7 │ │ 3 - ‡ │ + ⋮ │ 15 │ │ X2 Y2 Z2 16 │ │ X3 Y3 Z3 ╰╴ └──────────┘ `Y` is a good letter too @@ -1113,7 +1113,7 @@ error: foo 10 │ ┃│ 6 11 │ ┃│ X2 Y2 Z2 │ ┃└──────────┘ `Z` is a good letter too - ‡ ┃ + ⋮ ┃ 15 │ ┃ 10 16 │ ┃ X3 Y3 Z3 ╰╴┗━━━━━━━━┛ `Y` is a good letter @@ -1512,7 +1512,7 @@ LL │ Dst: TransmuteFrom ╰╴┗━━━━━━━━━━┛ required by this bound in `is_transmutable` "#]]; @@ -1806,7 +1806,7 @@ warning: non-local `macro_rules!` definition, `#[macro_export]` macro should be │ LL │ macro_rules! outer_macro { │ ──────────────────────── in this expansion of `nested_macro_rules::outer_macro!` - ‡ + ⋮ LL │ ┏ macro_rules! inner_macro { LL │ ┃ ($bang_macro:ident, $attr_macro:ident) => { LL │ ┃ $bang_macro!($name); @@ -2703,7 +2703,7 @@ error: unclosed frontmatter ╭▸ $DIR/unclosed-1.rs:1:1 │ LL │ ┏ ----cargo - ‡ ┃ + ⋮ ┃ LL │ ┃ │ ┗━┛ ╰╴ @@ -2776,7 +2776,7 @@ error: unclosed frontmatter ╭▸ $DIR/unclosed-2.rs:1:1 │ LL │ ┏ ----cargo - ‡ ┃ + ⋮ ┃ LL │ ┃ "----" LL │ ┃ } │ ┗━━┛ @@ -2982,7 +2982,7 @@ error: unclosed frontmatter ╭▸ $DIR/unclosed-5.rs:1:1 │ LL │ ┏ ----cargo - ‡ ┃ + ⋮ ┃ LL │ ┃ │ ┗━┛ ╰╴ @@ -4175,7 +4175,7 @@ error[E0599]: the method `quote_into_iter` exists for struct `Ipv4Addr`, but its │ LL │ struct Ipv4Addr; │ ─────────────── method `quote_into_iter` not found for this struct because it doesn't satisfy `Ipv4Addr: Iterator`, `Ipv4Addr: ToTokens`, `Ipv4Addr: proc_macro::ext::RepIteratorExt` or `Ipv4Addr: proc_macro::ext::RepToTokensExt` - ‡ + ⋮ LL │ let _ = quote! { $($ip)* }; //~ ERROR the method `quote_into_iter` exists for struct `Ipv4Addr`, but its trait bounds were not sat… │ ━━━━━━━━━━━━━━━━━━ method cannot be called on `Ipv4Addr` due to unsatisfied trait bounds │ @@ -4274,7 +4274,7 @@ error[E0220]: associated type `Pr` not found for `S` in the current scope │ LL │ struct S(T); │ ─────────── associated type `Pr` not found for this struct - ‡ + ⋮ LL │ let _: S::::Pr = (); │ ━━ associated item not found in `S` │ @@ -5508,7 +5508,7 @@ error[E0599]: no method named `bar` found for struct `Thing` in the current scop │ LL │ struct Thing { │ ──────────── method `bar` not found for this struct - ‡ + ⋮ LL │ t.bar(); │ ━━━ method not found in `Thing` ╰╴