From 26d38f2652f3ec79c20d926c2bf81d585a6645ed Mon Sep 17 00:00:00 2001 From: ueno Date: Sun, 7 Oct 2001 05:46:34 +0000 Subject: [PATCH] Synch up with liece-1_4. --- lisp/ChangeLog | 5 +++++ lisp/liece-misc.el | 7 ++++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fd5eaaf..46efc2b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2001-10-07 Daiki Ueno + + * liece-misc.el (liece-subtract-time): New function. + (liece-time-difference): Use it. + 2001-10-05 Daiki Ueno * liece-misc.el (liece-time-difference): Fix the arglist. diff --git a/lisp/liece-misc.el b/lisp/liece-misc.el index 51830c2..e479e43 100644 --- a/lisp/liece-misc.el +++ b/lisp/liece-misc.el @@ -432,12 +432,17 @@ found)) ;;; stolen (and renamed) from time-date.el. -(defun liece-time-difference (t1 t2) +(defun liece-subtract-time (t1 t2) "Subtract two internal times." (let ((borrow (< (cadr t1) (cadr t2)))) (list (- (car t1) (car t2) (if borrow 1 0)) (- (+ (if borrow 65536 0) (cadr t1)) (cadr t2))))) +(defun liece-time-difference (t1 t2) + "Return the differnce between two internal times in seconds." + (let ((sub (liece-subtract-time t1 t2))) + (+ (* (car sub) 65536) (cadr sub)))) + (defun liece-time-elapsed (time seconds) "Add SECONDS to TIME." (list (+ (car time) (/ (+ (cadr time) seconds) 65536)) -- 1.7.10.4