def seek_previous_line(self):
where = self.file.tell()<EOL>offset = <NUM_LIT:0><EOL>while True:<EOL><INDENT>if offset == where:<EOL><INDENT>break<EOL><DEDENT>read_size = self.read_size if self.read_size <= where else where<EOL>self.file.seek(where - offset - read_size, SEEK_SET)<EOL>data_len, data = self.read(read_size)<EOL>if b'<STR_LIT:\r\n>' in self.LINE_TERMINATORS and data[<NUM_LIT:0>] == b'<STR_LIT:\n>'[<NUM_LIT:0>]:<EOL><INDENT>terminator_where = self.file.tell()<EOL>if terminator_where > data_len + <NUM_LIT:1>:<EOL><INDENT>self.file.seek(where - offset - data_len - <NUM_LIT:1>, SEEK_SET)<EOL>terminator_len, terminator_data = self.read(<NUM_LIT:1>)<EOL>if terminator_data[<NUM_LIT:0>] == b'<STR_LIT:\r>'[<NUM_LIT:0>]:<EOL><INDENT>data_len += <NUM_LIT:1><EOL>data = b'<STR_LIT:\r>' + data<EOL><DEDENT>self.file.seek(terminator_where)<EOL><DEDENT><DEDENT>data_where = data_len<EOL>while data_where > <NUM_LIT:0>:<EOL><INDENT>terminator = self.suffix_line_terminator(data[:data_where])<EOL>if terminator and offset == <NUM_LIT:0> and data_where == data_len:<EOL><INDENT>data_where -= len(terminator)<EOL><DEDENT>elif terminator:<EOL><INDENT>self.file.seek(where - offset - (data_len - data_where))<EOL>return self.file.tell()<EOL><DEDENT>else:<EOL><INDENT>data_where -= <NUM_LIT:1><EOL><DEDENT><DEDENT>offset += data_len<EOL><DEDENT>if where == <NUM_LIT:0>:<EOL><INDENT>return -<NUM_LIT:1><EOL><DEDENT>else:<EOL><INDENT>self.file.seek(<NUM_LIT:0>)<EOL>return <NUM_LIT:0><EOL><DEDENT>
Seek previous line relative to the current file position.

:return: Position of the line or -1 if previous line was not found.