From 90cb669d58c8c4e535f2eac356f3e7c53a69b8cb Mon Sep 17 00:00:00 2001 From: Uttarayan Mondal Date: Fri, 12 Jul 2024 01:08:01 +0530 Subject: [PATCH] chore: Bump version to 0.27 for ratatui (#45) * chore: Update flake.nix * feat: Make 5.0.0-rc.1 release * feat: Cargo update * fix: Rebase merge from github ui Fix the rebase and merge which github ui fucked up * fix: The tests are updated to 0.27 * fix: cargo fmt * feat: added one more test for llvm-cov * feat: Replaced style methods with the faster version by default * feat: added more tests * fix: A overlooked bug in span impl --- Cargo.lock | 132 +++++++++++++++++++++++++++---------------------- Cargo.toml | 4 +- flake.lock | 52 ++++--------------- flake.nix | 25 +++++----- src/parser.rs | 110 +++++++++++++++++++++++------------------ tests/tests.rs | 53 ++++++++++++++++++-- 6 files changed, 208 insertions(+), 168 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 40695cf..6dff231 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -37,7 +37,7 @@ checksum = "4b46cbb362ab8752921c97e041f5e366ee6297bd428a31275b9fcf1e380f7299" [[package]] name = "ansi-to-tui" -version = "4.0.1" +version = "5.0.0-rc.1" dependencies = [ "anyhow", "criterion", @@ -57,9 +57,9 @@ checksum = "038dfcf04a5feb68e9c60b21c9625a54c2c0616e79b72b0fd87075a056ae1d1b" [[package]] name = "anyhow" -version = "1.0.83" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "25bdb32cbbdce2b519a9cd7df3a678443100e265d5e25ca763b7572a5104f5f3" +checksum = "b3d1d046238990b9cf5bcde22a3fb3584ee5cf65fb2765f454ed428c7a0063da" [[package]] name = "autocfg" @@ -135,18 +135,18 @@ dependencies = [ [[package]] name = "clap" -version = "4.5.4" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "90bc066a67923782aa8515dbaea16946c5bcc5addbd668bb80af688e53e548a0" +checksum = "5db83dced34638ad474f39f250d7fea9598bdd239eaced1bdf45d597da0f433f" dependencies = [ "clap_builder", ] [[package]] name = "clap_builder" -version = "4.5.2" +version = "4.5.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae129e2e766ae0ec03484e609954119f123cc1fe650337e155d03b022f24f7b4" +checksum = "f7e204572485eb3fbf28f871612191521df159bc3e15a9f5064c66dba3a8c05f" dependencies = [ "anstyle", "clap_lex", @@ -154,9 +154,9 @@ dependencies = [ [[package]] name = "clap_lex" -version = "0.7.0" +version = "0.7.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "98cc8fbded0c607b7ba9dd60cd98df59af97e84d24e49c8557331cfc26d301ce" +checksum = "4b82cf0babdbd58558212896d1a4272303a57bdb245c2bf1147185fb45640e70" [[package]] name = "compact_str" @@ -228,9 +228,9 @@ dependencies = [ [[package]] name = "crossbeam-utils" -version = "0.8.19" +version = "0.8.20" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "248e3bacc7dc6baa3b21e405ee045c3047101a49145e7e9eca583ab4c2ca5345" +checksum = "22ec99545bb0ed0ea7bb9b8e1e9122ea386ff8a48c0922e43f36d45ab09e0e80" [[package]] name = "crunchy" @@ -246,9 +246,9 @@ checksum = "56254986775e3233ffa9c4d7d3faaf6d36a2c09d30b20687e9f88bc8bafc16c8" [[package]] name = "either" -version = "1.11.0" +version = "1.12.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a47c1c47d2f5964e29c61246e81db715514cd532db6b5116a25ea3c03d6780a2" +checksum = "3dca9240753cf90908d7e4aac30f630662b02aebaa1b58a3cadabdb23385b58b" [[package]] name = "half" @@ -272,9 +272,9 @@ dependencies = [ [[package]] name = "heck" -version = "0.4.1" +version = "0.5.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "95505c38b4572b2d910cecb0281560f54b440a19336cbbcb27bf6ce6adc6f5a8" +checksum = "2304e00983f87ffb38b55b444b5e3b60a884b5d30c0fca7d82fe33449bbe55ea" [[package]] name = "hermit-abi" @@ -282,12 +282,6 @@ version = "0.3.9" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d231dfb89cfffdbc30e7fc41579ed6066ad03abda9e567ccafae602b97ec5024" -[[package]] -name = "indoc" -version = "2.0.5" -source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "b248f5224d1d606005e02c97f5aa4e88eeb230488bcc03bc9ca4d7991399f2b5" - [[package]] name = "is-terminal" version = "0.4.12" @@ -317,6 +311,15 @@ dependencies = [ "either", ] +[[package]] +name = "itertools" +version = "0.13.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "413ee7dfc52ee1a4949ceeb7dbc8a33f2d6c088194d9f922fb8318faf1f01186" +dependencies = [ + "either", +] + [[package]] name = "itoa" version = "1.0.11" @@ -334,9 +337,9 @@ dependencies = [ [[package]] name = "libc" -version = "0.2.154" +version = "0.2.155" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" +checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" [[package]] name = "log" @@ -355,9 +358,9 @@ dependencies = [ [[package]] name = "memchr" -version = "2.7.2" +version = "2.7.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6c8640c5d730cb13ebd907d8d04b52f55ac9a2eec55b440c8892f40d56c76c1d" +checksum = "78ca9ab1a0babb1e7d5695e3530886289c18cf2f87ec19a575a0abdce112e3a3" [[package]] name = "minimal-lexical" @@ -404,9 +407,9 @@ checksum = "57c0d7b74b563b49d38dae00a0c37d4d6de9b432382b2892f0574ddcae73fd0a" [[package]] name = "plotters" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "d2c224ba00d7cadd4d5c660deaf2098e5e80e07846537c51f9cfa4be50c1fd45" +checksum = "a15b6eccb8484002195a3e44fe65a4ce8e93a625797a063735536fd59cb01cf3" dependencies = [ "num-traits", "plotters-backend", @@ -417,15 +420,15 @@ dependencies = [ [[package]] name = "plotters-backend" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9e76628b4d3a7581389a35d5b6e2139607ad7c75b17aed325f210aa91f4a9609" +checksum = "414cec62c6634ae900ea1c56128dfe87cf63e7caece0852ec76aba307cebadb7" [[package]] name = "plotters-svg" -version = "0.3.5" +version = "0.3.6" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "38f6d39893cca0701371e3c27294f09797214b86f1fb951b89ade8ec04e2abab" +checksum = "81b30686a7d9c3e010b84284bdd26a29f2138574f52f5eb6f794fc0ad924e705" dependencies = [ "plotters-backend", ] @@ -442,9 +445,9 @@ dependencies = [ [[package]] name = "proc-macro2" -version = "1.0.82" +version = "1.0.86" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "8ad3d49ab951a01fbaafe34f2ec74122942fe18a3f9814c3268f1bb72042131b" +checksum = "5e719e8df665df0d1c8fbfd238015744736151d4445ec0836b8e628aae103b77" dependencies = [ "unicode-ident", ] @@ -460,20 +463,21 @@ dependencies = [ [[package]] name = "ratatui" -version = "0.26.2" +version = "0.27.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "a564a852040e82671dc50a37d88f3aa83bbc690dfc6844cfe7a2591620206a80" +checksum = "d16546c5b5962abf8ce6e2881e722b4e0ae3b6f1a08a26ae3573c55853ca68d3" dependencies = [ "bitflags", "cassowary", "compact_str", - "indoc", - "itertools 0.12.1", + "itertools 0.13.0", "lru", "paste", "stability", "strum", + "strum_macros", "unicode-segmentation", + "unicode-truncate", "unicode-width", ] @@ -499,9 +503,9 @@ dependencies = [ [[package]] name = "regex" -version = "1.10.4" +version = "1.10.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c117dbdfde9c8308975b6a18d71f3f385c89461f7b3fb054288ecf2a2058ba4c" +checksum = "b91213439dad192326a0d7c6ee3955910425f441d7038e0d6933b0aec5c4517f" dependencies = [ "aho-corasick", "memchr", @@ -511,9 +515,9 @@ dependencies = [ [[package]] name = "regex-automata" -version = "0.4.6" +version = "0.4.7" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "86b83b8b9847f9bf95ef68afb0b8e6cdb80f498442f5179a29fad448fcc1eaea" +checksum = "38caf58cc5ef2fed281f89292ef23f6365465ed9a41b7a7754eb4e26496c92df" dependencies = [ "aho-corasick", "memchr", @@ -522,9 +526,9 @@ dependencies = [ [[package]] name = "regex-syntax" -version = "0.8.3" +version = "0.8.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "adad44e29e4c806119491a7f06f03de4d1af22c3a680dd47f1e6e179439d1f56" +checksum = "7a66a03ae7c801facd77a29370b4faec201768915ac14a721ba36f20bc9c209b" [[package]] name = "rustversion" @@ -549,18 +553,18 @@ dependencies = [ [[package]] name = "serde" -version = "1.0.202" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "226b61a0d411b2ba5ff6d7f73a476ac4f8bb900373459cd00fab8512828ba395" +checksum = "7253ab4de971e72fb7be983802300c30b5a7f0c2e56fab8abfc6a214307c0094" dependencies = [ "serde_derive", ] [[package]] name = "serde_derive" -version = "1.0.202" +version = "1.0.203" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "6048858004bcff69094cd972ed40a32500f153bd3be9f716b2eed2e8217c4838" +checksum = "500cbc0ebeb6f46627f50f3f5811ccf6bf00643be300b4c3eabc0ef55dc5b5ba" dependencies = [ "proc-macro2", "quote", @@ -608,18 +612,18 @@ checksum = "a2eb9349b6444b326872e140eb1cf5e7c522154d69e7a0ffb0fb81c06b37543f" [[package]] name = "strum" -version = "0.26.2" +version = "0.26.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "5d8cec3501a5194c432b2b7976db6b7d10ec95c253208b45f83f7136aa985e29" +checksum = "8fec0f0aef304996cf250b31b5a10dee7980c85da9d759361292b8bca5a18f06" dependencies = [ "strum_macros", ] [[package]] name = "strum_macros" -version = "0.26.2" +version = "0.26.4" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "c6cf59daf282c0a494ba14fd21610a0325f9f90ec9d1231dea26bcb1d696c946" +checksum = "4c6bee85a5a24955dc440386795aa378cd9cf82acd5f764469152d2270e581be" dependencies = [ "heck", "proc-macro2", @@ -630,9 +634,9 @@ dependencies = [ [[package]] name = "syn" -version = "2.0.64" +version = "2.0.68" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "7ad3dee41f36859875573074334c200d1add8e4a87bb37113ebd31d926b7b11f" +checksum = "901fa70d88b9d6c98022e23b4136f9f3e54e4662c3bc1bd1d84a42a9a0f0c1e9" dependencies = [ "proc-macro2", "quote", @@ -641,18 +645,18 @@ dependencies = [ [[package]] name = "thiserror" -version = "1.0.60" +version = "1.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "579e9083ca58dd9dcf91a9923bb9054071b9ebbd800b342194c9feb0ee89fc18" +checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" dependencies = [ "thiserror-impl", ] [[package]] name = "thiserror-impl" -version = "1.0.60" +version = "1.0.61" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2470041c06ec3ac1ab38d0356a6119054dedaea53e12fbefc0de730a1c08524" +checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" dependencies = [ "proc-macro2", "quote", @@ -681,11 +685,21 @@ version = "1.11.0" source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "d4c87d22b6e3f4a18d4d40ef354e97c90fcb14dd91d7dc0aa9d8a1172ebf7202" +[[package]] +name = "unicode-truncate" +version = "1.0.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "5a5fbabedabe362c618c714dbefda9927b5afc8e2a8102f47f081089a9019226" +dependencies = [ + "itertools 0.12.1", + "unicode-width", +] + [[package]] name = "unicode-width" -version = "0.1.12" +version = "0.1.13" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "68f5e5f3158ecfd4b8ff6fe086db7c8467a2dfdac97fe420f2b7c4aa97af66d6" +checksum = "0336d538f7abc86d282a4189614dfaa90810dfc2c6f6427eaf88e16311dd225d" [[package]] name = "version_check" diff --git a/Cargo.toml b/Cargo.toml index 4b36e4e..b8bb099 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -1,6 +1,6 @@ [package] name = "ansi-to-tui" -version = "4.1.0" +version = "5.0.0-rc.1" authors = ["Uttarayan Mondal "] edition = "2018" description = "A library to convert ansi color coded text into ratatui::text::Text type from ratatui library" @@ -11,7 +11,7 @@ repository = "https://github.com/uttarayan21/ansi-to-tui" [dependencies] nom = "7.1" -tui = { version = "0.*,>=0.21,<0.27.0", default-features = false, package = "ratatui" } +tui = { version = "0.27", default-features = false, package = "ratatui" } thiserror = "1.0" simdutf8 = { version = "0.1", optional = true } smallvec = { version = "1.10.0", features = ["const_generics"] } diff --git a/flake.lock b/flake.lock index 85df9be..f255dcf 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1715274763, - "narHash": "sha256-3Iv1PGHJn9sV3HO4FlOVaaztOxa9uGLfOmUWrH7v7+A=", + "lastModified": 1718730147, + "narHash": "sha256-QmD6B6FYpuoCqu6ZuPJH896ItNquDkn0ulQlOn4ykN8=", "owner": "ipetkov", "repo": "crane", - "rev": "27025ab71bdca30e7ed0a16c88fd74c5970fc7f5", + "rev": "32c21c29b034d0a93fdb2379d6fabc40fc3d0e6c", "type": "github" }, "original": { @@ -38,31 +38,13 @@ "type": "github" } }, - "flake-utils_2": { - "inputs": { - "systems": "systems_2" - }, - "locked": { - "lastModified": 1705309234, - "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", - "owner": "numtide", - "repo": "flake-utils", - "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", - "type": "github" - }, - "original": { - "owner": "numtide", - "repo": "flake-utils", - "type": "github" - } - }, "nixpkgs": { "locked": { - "lastModified": 1715929032, - "narHash": "sha256-LtsvYEIz19/Tq0nfQFdL5ItHYYz26Jqpo3Hk1uEpsm0=", + "lastModified": 1719241184, + "narHash": "sha256-fz3Yc6bMhqhhF/xVrLE44Kew0/M78Xkl7sKXCfeFcI4=", "owner": "nixos", "repo": "nixpkgs", - "rev": "b4ee91268ecbdeaf0417db6e231be353dd7453f6", + "rev": "b4a237a1b79ef60236afef7b85d78118f3874d1d", "type": "github" }, "original": { @@ -81,17 +63,16 @@ }, "rust-overlay": { "inputs": { - "flake-utils": "flake-utils_2", "nixpkgs": [ "nixpkgs" ] }, "locked": { - "lastModified": 1715912155, - "narHash": "sha256-UXHk4dKvvm5mSuDDON3lXU5CHKiTRnIjA5mUtDOtKEU=", + "lastModified": 1719195554, + "narHash": "sha256-bFXHMjpYlEERexzXa1gLGJO/1l8dxaAtSNE56YALuTg=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "d3a96b08a7280a5753246129b462eed3662815d5", + "rev": "577ee84c69ba89894ac622d71a678a14d746b2f7", "type": "github" }, "original": { @@ -114,21 +95,6 @@ "repo": "default", "type": "github" } - }, - "systems_2": { - "locked": { - "lastModified": 1681028828, - "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", - "owner": "nix-systems", - "repo": "default", - "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", - "type": "github" - }, - "original": { - "owner": "nix-systems", - "repo": "default", - "type": "github" - } } }, "root": "root", diff --git a/flake.nix b/flake.nix index 2b14e73..7dda473 100644 --- a/flake.nix +++ b/flake.nix @@ -15,7 +15,6 @@ }; outputs = { - self, crane, flake-utils, nixpkgs, @@ -32,7 +31,7 @@ stableToolchain = pkgs.rust-bin.stable.latest.default; stableToolchainWithRustAnalyzer = pkgs.rust-bin.stable.latest.default.override { - extensions = ["rust-src" "rust-analyzer"]; + extensions = ["rust-src" "rust-analyzer" "llvm-tools"]; # Extra targets if required # targets = [ # "x86_64-unknown-linux-gnu" @@ -41,7 +40,7 @@ # "aarch64-apple-darwin" # ]; }; - craneLib = crane.lib.${system}.overrideToolchain stableToolchain; + craneLib = (crane.mkLib pkgs).overrideToolchain stableToolchain; craneLibLLvmTools = craneLib.overrideToolchain (pkgs.rust-bin.stable.latest.default.override { extensions = [ "cargo" @@ -93,17 +92,21 @@ }); }; - devShells.default = - (craneLib.overrideToolchain stableToolchainWithRustAnalyzer).devShell - ({ - buildInputs = []; - nativeBuildInputs = []; - packages = with pkgs; [ + devShells.default = (craneLib.overrideToolchain stableToolchainWithRustAnalyzer).devShell (commonArgs + // { + buildInputs = []; + nativeBuildInputs = []; + packages = with pkgs; + [ cargo-nextest cargo-criterion + cargo-outdated + cargo-mutants + ] + ++ lib.optionals pkgs.stdenv.isLinux [ + cargo-llvm-cov ]; - } - // commonArgs); + }); } ); } diff --git a/src/parser.rs b/src/parser.rs index 33825e0..467ca3f 100644 --- a/src/parser.rs +++ b/src/parser.rs @@ -71,7 +71,6 @@ impl From for tui::style::Style { } AnsiCode::ForegroundColor(color) => style = style.fg(color), AnsiCode::BackgroundColor(color) => style = style.bg(color), - AnsiCode::AlternateFonts(_) => (), _ => (), } } @@ -81,7 +80,7 @@ impl From for tui::style::Style { pub(crate) fn text(mut s: &[u8]) -> IResult<&[u8], Text<'static>> { let mut lines = Vec::new(); - let mut last = Default::default(); + let mut last = Style::new(); while let Ok((_s, (line, style))) = line(last)(s) { lines.push(line); last = style; @@ -96,7 +95,7 @@ pub(crate) fn text(mut s: &[u8]) -> IResult<&[u8], Text<'static>> { #[cfg(feature = "zero-copy")] pub(crate) fn text_fast(mut s: &[u8]) -> IResult<&[u8], Text<'_>> { let mut lines = Vec::new(); - let mut last = Default::default(); + let mut last = Style::new(); while let Ok((_s, (line, style))) = line_fast(last)(s) { lines.push(line); last = style; @@ -119,7 +118,7 @@ fn line(style: Style) -> impl Fn(&[u8]) -> IResult<&[u8], (Line<'static>, Style) // Since reset now tracks seperately we can skip the reset check last = last.patch(span.style); - if spans.is_empty() || !span.content.is_empty() { + if !span.content.is_empty() { spans.push(span); } text = s; @@ -144,7 +143,7 @@ fn line_fast(style: Style) -> impl Fn(&[u8]) -> IResult<&[u8], (Line<'_>, Style) last = last.patch(span.style); // If the spans is empty then it might be possible that the style changes // but there is no text change - if spans.is_empty() || !span.content.is_empty() { + if !span.content.is_empty() { spans.push(span); } text = s; @@ -164,12 +163,12 @@ fn span(last: Style) -> impl Fn(&[u8]) -> IResult<&[u8], Span<'static>, nom::err let (s, style) = opt(style(last))(s)?; #[cfg(feature = "simd")] - let (s, text) = map_res(take_while(|c| c != b'\x1b' | b'\n'), |t| { + let (s, text) = map_res(take_while(|c| c != b'\x1b' && c != b'\n'), |t| { simdutf8::basic::from_utf8(t) })(s)?; #[cfg(not(feature = "simd"))] - let (s, text) = map_res(take_while(|c| c != b'\x1b' | b'\n'), |t| { + let (s, text) = map_res(take_while(|c| c != b'\x1b' && c != b'\n'), |t| { std::str::from_utf8(t) })(s)?; @@ -185,15 +184,15 @@ fn span(last: Style) -> impl Fn(&[u8]) -> IResult<&[u8], Span<'static>, nom::err fn span_fast(last: Style) -> impl Fn(&[u8]) -> IResult<&[u8], Span<'_>, nom::error::Error<&[u8]>> { move |s: &[u8]| -> IResult<&[u8], Span<'_>> { let mut last = last; - let (s, style) = opt(style_fast(last))(s)?; + let (s, style) = opt(style(last))(s)?; #[cfg(feature = "simd")] - let (s, text) = map_res(take_while(|c| c != b'\x1b' | b'\n'), |t| { + let (s, text) = map_res(take_while(|c| c != b'\x1b' && c != b'\n'), |t| { simdutf8::basic::from_utf8(t) })(s)?; #[cfg(not(feature = "simd"))] - let (s, text) = map_res(take_while(|c| c != b'\x1b' | b'\n'), |t| { + let (s, text) = map_res(take_while(|c| c != b'\x1b' && c != b'\n'), |t| { std::str::from_utf8(t) })(s)?; @@ -201,7 +200,7 @@ fn span_fast(last: Style) -> impl Fn(&[u8]) -> IResult<&[u8], Span<'_>, nom::err last = last.patch(style); } - Ok((s, Span::styled(text.to_owned(), last))) + Ok((s, Span::styled(text, last))) } } @@ -210,33 +209,6 @@ fn style( ) -> impl Fn(&[u8]) -> IResult<&[u8], Option