(self, text : str)
| 311 | super().__init__(parent) |
| 312 | self.condition = None |
| 313 | def fromText(self, text : str): |
| 314 | if (not text.startswith("while")): |
| 315 | raise SyntaxError("While container does not start with while") |
| 316 | start = text.find("(") |
| 317 | end = text.rfind(")") |
| 318 | if (start == -1 or end == -1): |
| 319 | raise SyntaxError("While loop does not contain brackets") |
| 320 | self.condition = cleanCondition(text[start+1:end]) |
| 321 | def __str__(self): |
| 322 | spaces = "" |
| 323 | for _ in range(self.parent.depth): |
no test coverage detected