MCPcopy Create free account
hub / github.com/davidblewett/rure-python / count_tcl

Function count_tcl

regex/bench/src/main.rs:175–178  ·  view source on GitHub ↗
(pat: &str, haystack: &str)

Source from the content-addressed store, hash-verified

173nada!("re-tcl", count_tcl);
174#[cfg(feature = "re-tcl")]
175fn count_tcl(pat: &str, haystack: &str) -> usize {
176 use ffi::tcl::{Regex, Text};
177 Regex::new(pat).unwrap().find_iter(&Text::new(haystack.to_owned())).count()
178}

Callers 1

countMethod · 0.85

Calls 3

countMethod · 0.80
unwrapMethod · 0.80
find_iterMethod · 0.45

Tested by

no test coverage detected