From b33a81e40620b8b3eaeeec9d0e0b34ca5958dead Mon Sep 17 00:00:00 2001 From: Titus Wormer Date: Wed, 28 Sep 2022 17:54:39 +0200 Subject: Add support for turning mdast to hast --- src/construct/heading_setext.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'src/construct/heading_setext.rs') diff --git a/src/construct/heading_setext.rs b/src/construct/heading_setext.rs index 3a484e1..1e6fd00 100644 --- a/src/construct/heading_setext.rs +++ b/src/construct/heading_setext.rs @@ -77,7 +77,7 @@ use crate::state::{Name as StateName, State}; use crate::subtokenize::Subresult; use crate::tokenizer::Tokenizer; use crate::util::{constant::TAB_SIZE, skip}; -use alloc::{string::String, vec}; +use alloc::vec; /// At start of heading (setext) underline. /// @@ -184,7 +184,7 @@ pub fn after(tokenizer: &mut Tokenizer) -> State { } /// Resolve heading (setext). -pub fn resolve(tokenizer: &mut Tokenizer) -> Result, String> { +pub fn resolve(tokenizer: &mut Tokenizer) -> Option { tokenizer.map.consume(&mut tokenizer.events); let mut enter = skip::to(&tokenizer.events, 0, &[Name::HeadingSetextUnderline]); @@ -281,5 +281,5 @@ pub fn resolve(tokenizer: &mut Tokenizer) -> Result, String> { tokenizer.map.consume(&mut tokenizer.events); - Ok(None) + None } -- cgit