New-file position: the line number for additions, or the deletion boundary (the number of the preceding new line) for removals.
(&self)
| 792 | /// New-file position: the line number for additions, or the deletion |
| 793 | /// boundary (the number of the preceding new line) for removals. |
| 794 | fn new_pos(&self) -> usize { |
| 795 | match self.line.status { |
| 796 | LineStatus::Added => self.line.new_line_num.unwrap_or(1), |
| 797 | _ => { |
| 798 | (self.line.old_line_num.unwrap_or(1) as isize - 1 + self.net_before).max(0) as usize |
| 799 | } |
| 800 | } |
| 801 | } |
| 802 | } |
| 803 | |
| 804 | /// The engine's hunks-from-changed-lines core, as a free function (the |
no outgoing calls
no test coverage detected