1
Fork 0
mirror of https://git.savannah.gnu.org/git/guile.git synced 2025-04-30 11:50:28 +02:00

(group-diff): Also output +N and -N adds and subs details, respectively.

This commit is contained in:
Thien-Thi Nguyen 2002-05-19 05:12:04 +00:00
parent 0926d46e06
commit ef018514da

View file

@ -113,11 +113,23 @@ exec ${GUILE-guile} -l $0 -c "(apply $main (cdr (command-line)))" "$@"
(old-count (and old (length old))) (old-count (and old (length old)))
(new-count (and new (length new))) (new-count (and new (length new)))
(delta (and old new (- new-count old-count)))) (delta (and old new (- new-count old-count))))
(format #t " ~5@A ~5@A ~5@A ~A\n" (format #t " ~5@A ~5@A : "
(or old-count "-") (or old-count "-")
(or new-count "-") (or new-count "-"))
(or delta "-") (cond ((and old new)
group))) (let ((add-count 0) (sub-count 0))
(diff+note!
old new
(lambda (subs)
(set! sub-count (length subs)))
(lambda (adds)
(set! add-count (length adds)))
(lambda () #t))
(format #t "~5@D ~5@D : ~5@D"
add-count (- sub-count) delta)))
(else
(format #t "~5@A ~5@A : ~5@A" "-" "-" "-")))
(format #t " ~A\n" group)))
(sort (union g-old-names g-new-names) (sort (union g-old-names g-new-names)
(lambda (a b) (lambda (a b)
(string<? (symbol->string a) (string<? (symbol->string a)