MCPcopy Create free account
hub / github.com/Python-Markdown/markdown / parse_bogus_comment

Method parse_bogus_comment

markdown/htmlparser.py:349–356  ·  view source on GitHub ↗
(self, i: int, report: int = 0)

Source from the content-addressed store, hash-verified

347 return i + 2
348
349 def parse_bogus_comment(self, i: int, report: int = 0) -> int:
350 # Override the default behavior so that bogus comments get passed
351 # through unaltered by setting `report` to `0` (see #1425).
352 pos = super().parse_bogus_comment(i, report)
353 if pos == -1: # pragma: no cover
354 return -1
355 self.handle_empty_tag(self.rawdata[i:pos], is_block=False)
356 return pos
357
358 # The rest has been copied from base class in standard lib to address #1036.
359 # As `__startag_text` is private, all references to it must be in this subclass.

Callers 2

Calls 1

handle_empty_tagMethod · 0.95

Tested by

no test coverage detected