summaryrefslogtreecommitdiffstats
path: root/src/paint.rs
diff options
context:
space:
mode:
authorDan Davison <dandavison7@gmail.com>2020-08-01 22:58:27 -0400
committerDan Davison <dandavison7@gmail.com>2020-08-01 22:58:27 -0400
commit4a2ddc430e88bb6454032c8d2cfc4f7d3485b8d8 (patch)
treedd37fd455508c93bc1c0cca6ddfedd1f3d8a8b1b /src/paint.rs
parenta0853ca53ee622d159f39e0d9e0d84523252381a (diff)
Change parse_first_style() to take &str instead of bytes iterator
Diffstat (limited to 'src/paint.rs')
-rw-r--r--src/paint.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/paint.rs b/src/paint.rs
index 2639e1d0..0ef50fc1 100644
--- a/src/paint.rs
+++ b/src/paint.rs
@@ -306,7 +306,7 @@ impl<'a> Painter<'a> {
State::HunkMinus(None) => (config.minus_style, config.minus_non_emph_style),
State::HunkMinus(Some(raw_line)) => {
// TODO: This is the second time we are parsing the ANSI sequences
- if let Some(ansi_term_style) = ansi::parse::parse_first_style(raw_line.bytes()) {
+ if let Some(ansi_term_style) = ansi::parse::parse_first_style(raw_line) {
let style = Style {
ansi_term_style,
..Style::new()
@@ -320,7 +320,7 @@ impl<'a> Painter<'a> {
State::HunkPlus(None) => (config.plus_style, config.plus_non_emph_style),
State::HunkPlus(Some(raw_line)) => {
// TODO: This is the second time we are parsing the ANSI sequences
- if let Some(ansi_term_style) = ansi::parse::parse_first_style(raw_line.bytes()) {
+ if let Some(ansi_term_style) = ansi::parse::parse_first_style(raw_line) {
let style = Style {
ansi_term_style,
..Style::new()