def remove_line_breaks(source_lines):
    """
    expressions may be defined over multiple line using \ in python. This function removes this and joins lines.
    Args:
        source_lines:

    Returns:
        joined source without \ line breaks

    """
    source = ''
    last_line_had_break = False
    for line in source_lines:
        this_line_had_break = False
        if line.endswith('\\\n'):
            line = line[:-len('\\\n')]
            this_line_had_break = True

        # remove leading whitespace if last line had break
        if last_line_had_break:
            line = line.lstrip()

        source += line
        last_line_had_break = this_line_had_break
    return source