]> git.eshelyaron.com Git - emacs.git/commitdiff
(time-stamp-string-preprocess): Fix a wrong
authorGerd Moellmann <gerd@gnu.org>
Wed, 25 Oct 2000 12:08:59 +0000 (12:08 +0000)
committerGerd Moellmann <gerd@gnu.org>
Wed, 25 Oct 2000 12:08:59 +0000 (12:08 +0000)
type argument error.

lisp/ChangeLog
lisp/time-stamp.el

index 7882d1e4624bfeb3e35b54b406d3d9e696278047..9db8862f56301f6593c3b6d7de1d665705183165 100644 (file)
@@ -1,3 +1,8 @@
+2000-10-25  Stephen Gildea  <gildea@alum.mit.edu>
+
+       * time-stamp.el (time-stamp-string-preprocess): Fix a wrong
+       type argument error.
+
 2000-10-25  Miles Bader  <miles@gnu.org>
 
        * recentf.el (recentf-mode): Variable removed.
index 7768c74751f63471bff81ce710fcec3c97a75708..b34ddfe0b6085e6153ba93914aeababd9662c81e 100644 (file)
@@ -3,7 +3,7 @@
 ;; Copyright 1989, 1993, 1994, 1995, 1997, 2000
 ;;;    Free Software Foundation, Inc.
 
-;; Maintainer's Time-stamp: <2000-06-07 13:05:45 gildea>
+;; Maintainer's Time-stamp: <2000-10-23 16:08:34 gildea>
 ;; Maintainer: Stephen Gildea <gildea@alum.mit.edu>
 ;; Keywords: tools
 
@@ -575,23 +575,23 @@ Optionally use FORMAT."
         ((eq cur-char ?h)              ;mail host name
          (time-stamp-mail-host-name))
         ))
-       (if (string-equal field-width "")
-           field-result
-         (let ((padded-result
-                (format (format "%%%s%c"
-                                field-width
-                                (if (numberp field-result) ?d ?s))
-                        (or field-result ""))))
-           (let ((initial-length (length padded-result))
-                 (desired-length (string-to-int field-width)))
-             (if (> initial-length desired-length)
-                 ;; truncate strings on right, years on left
-                 (if (stringp field-result)
-                     (substring padded-result 0 desired-length)
-                   (if (eq cur-char ?y)
-                       (substring padded-result (- desired-length))
-                     padded-result))   ;non-year numbers don't truncate
-               padded-result)))))
+       (let ((padded-result
+              (format (format "%%%s%c"
+                              field-width
+                              (if (numberp field-result) ?d ?s))
+                      (or field-result ""))))
+         (let* ((initial-length (length padded-result))
+                (desired-length (if (string-equal field-width "")
+                                    initial-length
+                                  (string-to-int field-width))))
+           (if (> initial-length desired-length)
+               ;; truncate strings on right, years on left
+               (if (stringp field-result)
+                   (substring padded-result 0 desired-length)
+                 (if (eq cur-char ?y)
+                     (substring padded-result (- desired-length))
+                   padded-result))     ;non-year numbers don't truncate
+             padded-result))))
        (t
        (char-to-string cur-char)))))
       (setq ind (1+ ind)))