MCPcopy Index your code
hub / github.com/python/cpython / negative_lookahead

Method negative_lookahead

Tools/peg_generator/pegen/parser.py:286–290  ·  view source on GitHub ↗
(self, func: Callable[..., object], *args: object)

Source from the content-addressed store, hash-verified

284 return ok
285
286 def negative_lookahead(self, func: Callable[..., object], *args: object) -> bool:
287 mark = self._mark()
288 ok = func(*args)
289 self._reset(mark)
290 return not ok
291
292 def make_syntax_error(self, message: str, filename: str = "<unknown>") -> SyntaxError:
293 tok = self._tokenizer.diagnose()

Callers 1

target_atomMethod · 0.80

Calls 2

funcFunction · 0.50
_resetMethod · 0.45

Tested by

no test coverage detected