Syntactic sugar to easily instantiate a `CharsXY` at `(x,y)`. Note that the input arguments here are swapped. This is partly because of historical reasons, but also because virtually all editors (including this one) display file positions with the line first followed by the column. It's easier to reason about the tests below when the order of the arguments to `linecol` matches `yx`.
(y: u16, x: u16)
| 568 | /// with the line first followed by the column. It's easier to reason about the tests below |
| 569 | /// when the order of the arguments to `linecol` matches `yx`. |
| 570 | fn yx(y: u16, x: u16) -> CharsXY { |
| 571 | CharsXY::new(x, y) |
| 572 | } |
| 573 | |
| 574 | /// Syntactic sugar to easily instantiate a `FilePos` at `(line, col)`. |
| 575 | fn linecol(line: usize, col: usize) -> FilePos { |
no outgoing calls