Skip to content

Commit 20d508b

Browse files
committed
refactor: add some TODOs
1 parent ade71b1 commit 20d508b

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

src/visualizer/coloring.rs

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -46,19 +46,23 @@ pub enum Color {
4646
}
4747

4848
impl Color {
49+
// TODO: reconsider the visibility of this function once the TODOs in
50+
// `visualizer/methods.rs` have been dealt with.
4951
/// Get the ANSI prefix for this color from the given prefix table.
5052
pub(super) fn ansi_prefix(self, prefixes: &LsColors) -> AnsiPrefix<'_> {
5153
AnsiPrefix(prefixes.prefix_str(self))
5254
}
5355
}
5456

57+
// TODO: reconsider the of this struct once the TODOs in
58+
// `visualizer/methods.rs` have been dealt with.
5559
/// ANSI prefix wrapper for a [`Color`] variant, implements [`Display`].
5660
#[derive(Display)]
5761
pub(super) struct AnsiPrefix<'a>(&'a str);
5862

5963
impl AnsiPrefix<'_> {
6064
/// Returns the reset suffix to emit after this prefix, or `""` if no prefix.
61-
pub(super) fn suffix(&self) -> &'static str {
65+
fn suffix(&self) -> &'static str {
6266
if self.0.is_empty() {
6367
""
6468
} else {
@@ -69,6 +73,8 @@ impl AnsiPrefix<'_> {
6973

7074
/// A [`TreeHorizontalSlice`] with its color applied, used for rendering.
7175
pub(super) struct ColoredTreeHorizontalSlice<'a> {
76+
// TODO: reconsider the following visibilities once the TODOs in
77+
// `visualizer/methods.rs` have been dealt with.
7278
pub(super) slice: TreeHorizontalSlice<String>,
7379
pub(super) color: Color,
7480
pub(super) ls_colors: &'a LsColors,

0 commit comments

Comments
 (0)