fixup! block: fix parsing end of list
This commit is contained in:
parent
5d9f90342c
commit
f9655dfa9b
1 changed files with 4 additions and 6 deletions
10
src/block.rs
10
src/block.rs
|
@ -805,12 +805,10 @@ impl Kind {
|
|||
..
|
||||
} => {
|
||||
let spaces = line.chars().take_while(|c| c.is_whitespace()).count();
|
||||
if matches!(next, Self::Atom(Blankline)) {
|
||||
*last_blankline = true;
|
||||
true
|
||||
} else {
|
||||
spaces > *indent || (!*last_blankline && matches!(next, Self::Paragraph))
|
||||
}
|
||||
let para = !*last_blankline && matches!(next, Self::Paragraph);
|
||||
let blankline = matches!(next, Self::Atom(Blankline));
|
||||
*last_blankline = blankline;
|
||||
blankline || spaces > *indent || para
|
||||
}
|
||||
Self::Definition { indent, footnote } => {
|
||||
if *footnote {
|
||||
|
|
Loading…
Reference in a new issue