Remove unnecessary context from some util functions.
This commit is contained in:
@@ -37,7 +37,7 @@ pub fn greater_block<'r, 's>(
|
||||
input: OrgSource<'s>,
|
||||
) -> Res<OrgSource<'s>, GreaterBlock<'s>> {
|
||||
// TODO: Do I need to differentiate between different greater block types.
|
||||
start_of_line(context, input)?;
|
||||
start_of_line(input)?;
|
||||
let (remaining, _leading_whitespace) = space0(input)?;
|
||||
let (remaining, (_begin, name)) = tuple((
|
||||
tag_no_case("#+begin_"),
|
||||
@@ -125,7 +125,7 @@ fn greater_block_end<'r, 's>(
|
||||
context: Context<'r, 's>,
|
||||
input: OrgSource<'s>,
|
||||
) -> Res<OrgSource<'s>, OrgSource<'s>> {
|
||||
start_of_line(context, input)?;
|
||||
start_of_line(input)?;
|
||||
let current_name: &str = get_context_greater_block_name(context).ok_or(nom::Err::Error(
|
||||
CustomError::MyError(MyError("Not inside a greater block".into())),
|
||||
))?;
|
||||
|
||||
Reference in New Issue
Block a user