From 3fc3ba58aad714fba6dea1f18baa77b2ee0ec387 Mon Sep 17 00:00:00 2001 From: Tom Alexander Date: Mon, 24 Apr 2023 20:41:40 -0400 Subject: [PATCH] Defining the RadioTarget context element. --- src/parser/parser_context.rs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/parser/parser_context.rs b/src/parser/parser_context.rs index 232db31..616b983 100644 --- a/src/parser/parser_context.rs +++ b/src/parser/parser_context.rs @@ -6,6 +6,7 @@ use nom::IResult; use super::list::List; use super::list::Node; use super::Context; +use super::Object; use crate::error::CustomError; use crate::error::MyError; use crate::error::Res; @@ -133,6 +134,13 @@ pub enum ContextElement<'r, 's> { /// Indicates if elements should consume the whitespace after them. ConsumeTrailingWhitespace(bool), + + /// The contents of a radio target. + /// + /// If any are found, this will force a 2nd parse through the + /// org-mode document since text needs to be re-parsed to look for + /// radio links matching the contents of radio targets. + RadioTarget(Vec>>), } pub struct ExitMatcherNode<'r> {