Lines Matching defs:line
139 pos: Cell::new(Position { offset: 0, line: 1, column: 1 }),
207 /// started using `#` and continue until the end of the line.
356 // These settings should be in line with the construction
358 self.pos.set(Position { offset: 0, line: 1, column: 1 });
395 /// Return the current line number of the parser.
397 /// The line number starts at `1`.
398 fn line(&self) -> usize {
399 self.parser().pos.get().line
472 let Position { mut offset, mut line, mut column } = self.pos();
474 line = line.checked_add(1).unwrap();
480 self.parser().pos.set(Position { offset, line, column });
605 /// line and column.
620 line: self.line(),
624 next.line += 1;
2376 fn npos(offset: usize, line: usize, column: usize) -> Position {
2377 Position::new(offset, line, column)
2381 /// line and sets the columns based on the offsets. i.e., This only works
2393 line: 1 + subject[..range.start].matches('\n').count(),
2402 line: 1 + subject[..range.end].matches('\n').count(),