Consume trailing whitespace after a plain link.
rustfmt Build rustfmt has succeeded Details
rust-test Build rust-test has succeeded Details
rust-build Build rust-build has succeeded Details

main
Tom Alexander 7 months ago
parent 84edd10864
commit 28b2d27054
Signed by: talexander
GPG Key ID: D3A179C9A53C0EDE

@ -0,0 +1 @@
This folder contains org-mode documents that get automatically included as tests using build.rs.

@ -11,6 +11,7 @@ use nom::combinator::verify;
use nom::multi::many_till;
use super::org_source::OrgSource;
use super::util::maybe_consume_object_trailing_whitespace_if_not_exiting;
use crate::context::parser_with_context;
use crate::context::ContextElement;
use crate::context::ExitClass;
@ -61,6 +62,8 @@ pub fn plain_link<'b, 'g, 'r, 's>(
let (remaining, _separator) = tag(":")(remaining)?;
let (remaining, path) = path_plain(context, remaining)?;
peek(parser_with_context!(post)(context))(remaining)?;
let (remaining, _trailing_whitespace) =
maybe_consume_object_trailing_whitespace_if_not_exiting(context, remaining)?;
let source = get_consumed(input, remaining);
Ok((
remaining,

Loading…
Cancel
Save