From f24123f943abaebffd098a12069bcca62181f862 Mon Sep 17 00:00:00 2001 From: SoniEx2 Date: Sat, 6 Aug 2022 15:06:18 -0300 Subject: Fix predicates --- src/vm.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'src/vm.rs') diff --git a/src/vm.rs b/src/vm.rs index 6bcbf70..ac5c95d 100644 --- a/src/vm.rs +++ b/src/vm.rs @@ -1,17 +1,24 @@ // Copyright (C) 2021-2022 Soni L. // SPDX-License-Identifier: MIT OR Apache-2.0 +//! The Datafu Virtual Machine. +//! +//! This is the stuff that actually matches the pattern. + use regex::Regex; use serde::Serialize; use crate::Predicate; //use crate::errors::MatchError; +mod de; + +/// Max depth for VM/serde recursion. pub(crate) const MAX_CALLS: usize = 250; //type Matches<'a, 'b, T> = BTreeMap<&'a str, KVPair<'b, T>>; -// TODO: use a builder for this? +// maybe we should use a builder for this? /// The constant pool for a pattern. pub(crate) struct PatternConstants { // last proto is implicitly the whole pattern. -- cgit 1.4.1