#regex #checking #checker #regular #expression

iregexp

A checking implementation of I-Regexp

2 releases

0.1.1 May 14, 2024
0.1.0 May 13, 2024

#22 in #checker

Download history 241/week @ 2024-05-13

241 downloads per month

MIT license

12KB
173 lines

Rust I-Regexp Checker

Check regular expressions for compliance with RFC 9485.

use iregexp::check;

fn main() {
    println!("{:?}", check(r"[0-9]*?"));  // false
}

lib.rs:

A checking implementation of I-Regexp.

let valid = iregexp::check(r"[ab]{3}");
assert_eq!(valid, true);

let valid = iregexp::check(r"[0-9]*?");
assert_eq!(valid, false);

Dependencies

~2.2–3MB
~59K SLoC