2.12.2021, 9:00 - 11:00: Due to updates GitLab may be unavailable for some minutes between 09:00 and 11:00.

Commit 970b4941 authored by eckhart's avatar eckhart
Browse files

parse.py: bug fix repr-property of Forward-parsers

parent 628adcb1
......@@ -1947,6 +1947,11 @@ class Forward(Parser):
def __str__(self):
return self.__cycle_guard(lambda: str(self.parser), '...')
@property
def repr(self) -> str:
"""Returns the parser's name if it has a name and repr()"""
return self.parser.name if self.parser.name else repr(self)
def set(self, parser: Parser):
"""
Sets the parser to which the calls to this Forward-object
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment