From ffe267be7a725c776ebc92d6551e8a070aadf254 Mon Sep 17 00:00:00 2001 From: René Kijewski Date: Tue, 1 Aug 2023 10:28:17 +0200 Subject: parser: add `Ast::nodes()` method --- askama_parser/src/lib.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'askama_parser') diff --git a/askama_parser/src/lib.rs b/askama_parser/src/lib.rs index 6ff9360..43d953d 100644 --- a/askama_parser/src/lib.rs +++ b/askama_parser/src/lib.rs @@ -105,6 +105,10 @@ impl<'a> Ast<'a> { Err(ParseError(msg)) } + + pub fn nodes(&self) -> &[Node<'a>] { + &self.nodes + } } #[derive(Debug, Clone, PartialEq, Eq)] -- cgit