def assert_end(self, *, allowSemicolon: bool=False) -> None:
    self.skip_ws()
    if allowSemicolon:
        if ((not self.eof) and (self.definition[self.pos:] != ';')):
            self.fail('Expected end of definition or ;.')
    elif (not self.eof):
        self.fail('Expected end of definition.')
def assert_end(self, *, allowSemicolon: bool=False) -> None:
    self.skip_ws()
    if allowSemicolon:
        if ((not self.eof) and (self.definition[self.pos:] != ';')):
            self.fail('Expected end of definition or ;.')
    elif (not self.eof):
        self.fail('Expected end of definition.')