23 releases

0.9.1 Oct 12, 2021
0.8.5 Oct 11, 2021
0.8.4 Oct 11, 2020
0.8.1 Jun 22, 2020
0.2.1 Dec 27, 2018

#79 in #escaping

Download history 3543/week @ 2024-12-10 2753/week @ 2024-12-17 1203/week @ 2024-12-24 2008/week @ 2024-12-31 2649/week @ 2025-01-07 4359/week @ 2025-01-14 3016/week @ 2025-01-21 2904/week @ 2025-01-28 7746/week @ 2025-02-04 3442/week @ 2025-02-11 2465/week @ 2025-02-18 4374/week @ 2025-02-25 3100/week @ 2025-03-04 4955/week @ 2025-03-11 5380/week @ 2025-03-18 5244/week @ 2025-03-25

19,304 downloads per month
Used in 117 crates (via v_escape)

MIT/Apache

28KB
769 lines

v_escape Documentation Latest version

The simd optimized escape code

Crate v_escape provides a macro new_escape! that define a escaping functionalities. These macros are optimized using simd by default, but this can be altered using sub-attributes.

Documentation

Example

v_escape::new!(MyEscape; '<' -> "bar");

fn main() {
    let s = "foo<bar";
    
    print!("{}", MyEscape::from(s));
    assert_eq!(MyEscape::from(s).to_string(), "foobarbar");
}

Dependencies

~1.5MB
~38K SLoC