diff --git a/inline/src/lexer/token.rs b/inline/src/lexer/token.rs index 860de870..5350a688 100644 --- a/inline/src/lexer/token.rs +++ b/inline/src/lexer/token.rs @@ -687,6 +687,20 @@ impl TokenDelimiters { self.close.as_ref().map(TokenKind::as_str), ) } + + /// Returns the opening [`TokenKind`] + /// + /// [`TokenKind`]: self::TokenKind + pub fn open(&self) -> TokenKind { + self.open + } + + /// Returns the opening [`TokenKind`] if available. + /// + /// [`TokenKind`]: self::TokenKind + pub fn close(&self) -> Option { + self.close + } } /// Enum representing the spacing surrounding a particular token in Unimarkup document.