regex: enable perf-dfa so the dfa_size_limit on user patterns applies

Without the feature the lazy-DFA cache does not exist and the limit set in
UserRegex::new does nothing. Matching stays linear-time.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
vangel76andClaude Sonnet 5.5 committed 2026-11-07 16:40:37 +01:00
1 parent 81af7f1cd9
commit cc4bd4914c
1 file changed
+3 -2
+3 -2
View File
@@ -80,8 +80,9 @@ hayro-jbig2 = "0.3"
# foundation
thiserror = "2"
# Linear-time matching (no backtracking) for caller-supplied redaction patterns.
regex = { version = "1", default-features = false, features = ["std", "unicode"] }
# Linear-time matching (no backtracking) for caller-supplied redaction patterns. `perf-dfa` gives
# the lazy-DFA cache that `RegexBuilder::dfa_size_limit` bounds (the limit is inert without it).
regex = { version = "1", default-features = false, features = ["std", "unicode", "perf-dfa"] }
serde = { version = "1", features = ["derive", "rc"] }
serde_json = "1"
log = "0.4"