Skip to content

Error with redact() function - regex parse error: look-around, including look-ahead and look-behind, is not supported: ^^^: #22600

Answered by jszwedko
JustinJKelly asked this question in Q&A
Discussion options

You must be logged in to vote

Hey! Unfortunately it has not. This regex library Vector uses puts an emphasis on bounded performance of regular expressions and those sorts of regex operations (lookaround and backreferences) can explode the computation required. This is mentioned in the library documentation:

This crate provides routines for searching strings for matches of a regular expression (aka “regex”). The regex syntax supported by this crate is similar to other regex engines, but it lacks several features that are not known how to implement efficiently. This includes, but is not limited to, look-around and backreferences. In exchange, all regex searches in this crate have worst case O(m * n) time complexity, wh…

Replies: 1 comment 1 reply

Comment options

You must be logged in to vote
1 reply
@JustinJKelly
Comment options

Answer selected by JustinJKelly
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants