From 96d4ca5f7349f2df6c3e9a949242a0e49b2ce853 Mon Sep 17 00:00:00 2001 From: Skyler Hawthorne Date: Mon, 17 Jan 2022 20:41:44 -0500 Subject: [PATCH] Dependabot/cargo/pulldown cmark 0.9.1 (#1533) * build(deps): bump pulldown-cmark from 0.8.0 to 0.9.1 Bumps [pulldown-cmark](https://github.com/raphlinus/pulldown-cmark) from 0.8.0 to 0.9.1. - [Release notes](https://github.com/raphlinus/pulldown-cmark/releases) - [Commits](https://github.com/raphlinus/pulldown-cmark/compare/v0.8.0...v0.9.1) --- updated-dependencies: - dependency-name: pulldown-cmark dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * cmark 0.9 fixes Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> --- Cargo.lock | 4 ++-- helix-term/Cargo.toml | 2 +- helix-term/src/ui/markdown.rs | 6 ++++-- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/Cargo.lock b/Cargo.lock index 8e4d941ba..dbafd95c9 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -758,9 +758,9 @@ dependencies = [ [[package]] name = "pulldown-cmark" -version = "0.8.0" +version = "0.9.1" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "ffade02495f22453cd593159ea2f59827aae7f53fa8323f756799b670881dcf8" +checksum = "34f197a544b0c9ab3ae46c359a7ec9cbbb5c7bf97054266fecb7ead794a181d6" dependencies = [ "bitflags", "memchr", diff --git a/helix-term/Cargo.toml b/helix-term/Cargo.toml index 28b4fe2ad..e379b369e 100644 --- a/helix-term/Cargo.toml +++ b/helix-term/Cargo.toml @@ -46,7 +46,7 @@ log = "0.4" fuzzy-matcher = "0.3" ignore = "0.4" # markdown doc rendering -pulldown-cmark = { version = "0.8", default-features = false } +pulldown-cmark = { version = "0.9", default-features = false } # file type detection content_inspector = "0.2.4" diff --git a/helix-term/src/ui/markdown.rs b/helix-term/src/ui/markdown.rs index 46657fb9a..1f0fc38c7 100644 --- a/helix-term/src/ui/markdown.rs +++ b/helix-term/src/ui/markdown.rs @@ -77,7 +77,9 @@ fn parse<'a>( Event::End(tag) => { tags.pop(); match tag { - Tag::Heading(_) | Tag::Paragraph | Tag::CodeBlock(CodeBlockKind::Fenced(_)) => { + Tag::Heading(_, _, _) + | Tag::Paragraph + | Tag::CodeBlock(CodeBlockKind::Fenced(_)) => { // whenever code block or paragraph closes, new line let spans = std::mem::take(&mut spans); if !spans.is_empty() { @@ -158,7 +160,7 @@ fn parse<'a>( lines.push(Spans::from(span)); } } - } else if let Some(Tag::Heading(_)) = tags.last() { + } else if let Some(Tag::Heading(_, _, _)) = tags.last() { let mut span = to_span(text); span.style = heading_style; spans.push(span);