MCPcopy Index your code
hub / github.com/RustPython/RustPython / trim_matches

Method trim_matches

crates/wtf8/src/lib.rs:1108–1110  ·  view source on GitHub ↗
(&self, f: impl Fn(CodePoint) -> bool)

Source from the content-addressed store, hash-verified

1106 }
1107
1108 pub fn trim_matches(&self, f: impl Fn(CodePoint) -> bool) -> &Self {
1109 self.trim_start_matches(&f).trim_end_matches(&f)
1110 }
1111
1112 pub fn find(&self, pat: &Wtf8) -> Option<usize> {
1113 memchr::memmem::find(self.as_bytes(), pat.as_bytes())

Callers 1

stripMethod · 0.80

Calls 2

trim_end_matchesMethod · 0.80
trim_start_matchesMethod · 0.80

Tested by

no test coverage detected