Home
last modified time | relevance | path

Searched refs:line_col (Results 1 – 2 of 2) sorted by relevance

/qemu/scripts/codeconverter/codeconverter/
H A Dutils.py50 def line_col(s, position: int) -> LineAndColumn: function
62 assert line_col('abc\ndefg\nhijkl', 0) == (1, 1)
63 assert line_col('abc\ndefg\nhijkl', 2) == (1, 3)
64 assert line_col('abc\ndefg\nhijkl', 3) == (1, 4)
65 assert line_col('abc\ndefg\nhijkl', 4) == (2, 1)
66 assert line_col('abc\ndefg\nhijkl', 10) == (3, 2)
H A Dpatching.py68 def line_col(self) -> LineAndColumn: member in FileMatch
69 return self.file.line_col(self.start())
80 pos = self.line_col()
147 start = self.file.line_col(self.start())
148 end = self.file.line_col(self.end() - 1)
252 p.start, line_col(s, p.start),
253 p.end, line_col(s, p.end),
257 (p.start, line_col(s, p.start), last, line_col(s, last)))
320 def line_col(self, start: int) -> LineAndColumn: member in FileInfo
322 return line_col(self.original_content, start)
[all …]