aboutsummaryrefslogtreecommitdiff
path: root/src/fexpr/mod.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/fexpr/mod.rs')
-rw-r--r--src/fexpr/mod.rs6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/fexpr/mod.rs b/src/fexpr/mod.rs
index c6a3a39..5d12051 100644
--- a/src/fexpr/mod.rs
+++ b/src/fexpr/mod.rs
@@ -11,6 +11,12 @@ use itertools::Itertools;
use lalrpop_util::{lalrpop_mod, lexer::Token, ParseError};
use thiserror::Error;
+// Lalrpop chokes on the associated type specification (it doesn't expect the =), so we need to
+// define those aliases here in Rust and then import and use them in the grammar.
+trait DateProducer = filters::values::Producer<Output = chrono::DateTime<chrono::Utc>>;
+trait DurationProducer = filters::values::Producer<Output = chrono::Duration>;
+trait CountProducer = filters::values::Producer<Output = u8>;
+
lalrpop_mod!(#[allow(clippy::all)] pub grammar, "/fexpr/grammar.rs");
#[derive(Debug)]