Finalize definition block.
(self)
| 576 | self.context.pop() |
| 577 | |
| 578 | def finalize_block(self) -> None: |
| 579 | """Finalize definition block.""" |
| 580 | definition = self.indents.pop() |
| 581 | if definition[0] != 'other': |
| 582 | typ, funcname, start_pos = definition |
| 583 | end_pos = self.current.end[0] - 1 # type: ignore[union-attr] |
| 584 | while emptyline_re.match(self.get_line(end_pos)): |
| 585 | end_pos -= 1 |
| 586 | |
| 587 | self.add_definition(funcname, (typ, start_pos, end_pos)) # type: ignore[arg-type] |
| 588 | self.context.pop() |
| 589 | |
| 590 | |
| 591 | class Parser: |
no test coverage detected