We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3cdec5a commit 88e7939Copy full SHA for 88e7939
src/main.rs
@@ -351,7 +351,7 @@ pub struct Commit {
351
}
352
353
impl Commit {
354
- pub fn loc(&self, filter: &Filter) -> u32 {
+ pub fn loc(&self, filter: &Filter) -> i64 {
355
self.locs.iter().filter(|l| filter.check_loc(l)).map(|l| l.loc()).sum()
356
357
@@ -430,11 +430,11 @@ impl Loc {
430
})
431
432
433
- fn loc(&self) -> u32 {
+ fn loc(&self) -> i64 {
434
if self.added.is_none() && self.removed.is_none() {
435
0
436
} else {
437
- (self.added.unwrap() as i64 - self.removed.unwrap() as i64).abs() as u32
+ self.added.unwrap() as i64 - self.removed.unwrap() as i64
438
439
440
0 commit comments