def line_iterator_to_intermediary(line_iterator):
    """ Parse an iterator of str (one string per line) to the intermediary syntax"""
    current_table = None
    tables = []
    relations = []
    errors = []
    for line_nb, line, raw_line in filter_lines_from_comments(line_iterator):
        try:
            new_obj = parse_line(line)
            current_table, tables, relations = update_models(new_obj, current_table, tables, relations)
        except ParsingException as e:
            e.line_nb = line_nb
            e.line = raw_line
            errors.append(e)
    if len(errors) != 0:
        msg = 'ERAlchemy couldn\'t complete the generation due the {} following errors'.format(len(errors))
        raise ParsingException(msg * '\n\n'.join(e.traceback for e in errors))
    return tables, relations
dataset/ETHPy150Open Alexis-benoist/eralchemy/eralchemy/parser.py/line_iterator_to_intermediary/operator `+` -> `*`