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

Method reset

crates/sre_engine/src/engine.rs:126–131  ·  view source on GitHub ↗
(&mut self, req: &Request<'_, S>, start: usize)

Source from the content-addressed store, hash-verified

124
125impl State {
126 pub fn reset<S: StrDrive>(&mut self, req: &Request<'_, S>, start: usize) {
127 self.marks.clear();
128 self.repeat_stack.clear();
129 self.start = start;
130 req.string.adjust_cursor(&mut self.cursor, start);
131 }
132
133 pub fn py_match<S: StrDrive>(&mut self, req: &Request<'_, S>) -> bool {
134 self.start = req.start;

Callers 3

searchMethod · 0.45
nextMethod · 0.45
search_info_literalFunction · 0.45

Calls 2

adjust_cursorMethod · 0.80
clearMethod · 0.45

Tested by

no test coverage detected