Make the item tag exit matcher a lower class than all all others.
This is to allow for " :: " inside a description list item's tag if it is nested inside another object.
This commit is contained in:
@@ -108,7 +108,7 @@ impl<'g, 'r, 's> Context<'g, 'r, 's> {
|
||||
&'r self,
|
||||
i: OrgSource<'s>,
|
||||
) -> IResult<OrgSource<'s>, OrgSource<'s>, CustomError<OrgSource<'s>>> {
|
||||
let mut current_class_filter = ExitClass::Gamma;
|
||||
let mut current_class_filter = ExitClass::Delta;
|
||||
for current_node in self.iter_context() {
|
||||
let context_element = current_node.get_data();
|
||||
match context_element {
|
||||
|
||||
@@ -1,16 +1,10 @@
|
||||
#[derive(Debug, Copy, Clone)]
|
||||
pub enum ExitClass {
|
||||
/// Headlines and sections.
|
||||
Document = 1,
|
||||
|
||||
/// Elements who take priority over beta elements when matching.
|
||||
Alpha = 20,
|
||||
|
||||
/// Elements who cede priority to alpha elements when matching.
|
||||
Beta = 300,
|
||||
|
||||
/// Elements who cede priority to alpha and beta elements when matching.
|
||||
Gamma = 4000,
|
||||
Alpha = 2,
|
||||
Beta = 3,
|
||||
Gamma = 4,
|
||||
Delta = 5,
|
||||
}
|
||||
|
||||
impl std::fmt::Display for ExitClass {
|
||||
|
||||
Reference in New Issue
Block a user