From 60cb53cafeece862cd0a7a2f8dce1f6e102cea94 Mon Sep 17 00:00:00 2001 From: Ben Bridle Date: Sun, 14 Jun 2026 14:32:56 +1200 Subject: Only detect monospace elements in pipe-avoiding table cell parser This is a hacky fix to allow me to use the dollar sign as a regular character inside table cells. The pipe character will realistically only be used inside monospace elements anyway. --- src/table.rs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/table.rs b/src/table.rs index bfd9177..59f6ae7 100644 --- a/src/table.rs +++ b/src/table.rs @@ -75,10 +75,8 @@ fn split_columns(line: &str) -> Option> { for c in head.chars() { if Some(c) == context { context = None; - } else if Some(c) == context { - context = None; } else if context.is_none() { - if "$`*_".contains(c) { + if c == '`' { context = Some(c); } else if c == '|' && context.is_none() { if !cell.is_empty() { -- cgit v1.3.1