fixup! inline fixup

This commit is contained in:
Noah Hellman 2023-01-30 23:26:35 +01:00
parent 8dd4db11ec
commit 4b52fb0832

View file

@ -441,13 +441,14 @@ impl<I: Iterator<Item = char> + Clone> Parser<I> {
self.openers.drain(o..);
if let Some(event_closer) = &mut event_closer {
if event_closer.span.is_empty() {
assert!(matches!(
if event_closer.span.is_empty()
&& matches!(
event_closer.kind,
EventKind::Exit(
Container::ReferenceLink | Container::ReferenceImage
)
));
)
{
assert_eq!(self.events[e_opener].span, event_closer.span);
event_closer.span = inner_span;
self.events[e_opener].span = inner_span;