[slime-cvs] CVS slime/contrib

CVS User sboukarev sboukarev at common-lisp.net
Fri Apr 6 18:08:31 UTC 2012


Update of /project/slime/cvsroot/slime/contrib
In directory tiger.common-lisp.net:/tmp/cvs-serv19546

Modified Files:
	ChangeLog swank-fancy-inspector.lisp 
Log Message:
* swank-fancy-inspector.lisp (format-iso8601-time): Add 1 to the
time-zone if DST value of decode-universal-time is T.


--- /project/slime/cvsroot/slime/contrib/ChangeLog	2012/04/04 12:04:42	1.540
+++ /project/slime/cvsroot/slime/contrib/ChangeLog	2012/04/06 18:08:30	1.541
@@ -1,3 +1,8 @@
+2012-04-06  Stas Boukarev  <stassats at gmail.com>
+
+	* swank-fancy-inspector.lisp (format-iso8601-time): Add 1 to the
+	time-zone if DST value of decode-universal-time is T.
+
 2012-04-04  Nikodemus Siivola  <nikodemus at random-state.net>
 
 	* slime-cl-indent.el (common-lisp-lambda-list-initial-value-form-p): New function.
--- /project/slime/cvsroot/slime/contrib/swank-fancy-inspector.lisp	2011/12/01 16:48:22	1.32
+++ /project/slime/cvsroot/slime/contrib/swank-fancy-inspector.lisp	2012/04/06 18:08:30	1.33
@@ -765,24 +765,26 @@
   `("Value: " ,(princ-to-string n)))
 
 (defun format-iso8601-time (time-value &optional include-timezone-p)
-    "Formats a universal time TIME-VALUE in ISO 8601 format, with
+  "Formats a universal time TIME-VALUE in ISO 8601 format, with
     the time zone included if INCLUDE-TIMEZONE-P is non-NIL"    
-    ;; Taken from http://www.pvv.ntnu.no/~nsaa/ISO8601.html
-    ;; Thanks, Nikolai Sandved and Thomas Russ!
-    (flet ((format-iso8601-timezone (zone)
-             (if (zerop zone)
-                 "Z"
-                 (multiple-value-bind (h m) (truncate (abs zone) 1.0)
-                   ;; Tricky.  Sign of time zone is reversed in ISO 8601
-                   ;; relative to Common Lisp convention!
-                   (format nil "~:[+~;-~]~2,'0D:~2,'0D"
-                           (> zone 0) h (round (* 60 m)))))))
+  ;; Taken from http://www.pvv.ntnu.no/~nsaa/ISO8601.html
+  ;; Thanks, Nikolai Sandved and Thomas Russ!
+  (flet ((format-iso8601-timezone (zone)
+           (if (zerop zone)
+               "Z"
+               (multiple-value-bind (h m) (truncate (abs zone) 1.0)
+                 ;; Tricky.  Sign of time zone is reversed in ISO 8601
+                 ;; relative to Common Lisp convention!
+                 (format nil "~:[+~;-~]~2,'0D:~2,'0D"
+                         (> zone 0) h (round (* 60 m)))))))
     (multiple-value-bind (second minute hour day month year dow dst zone)
-      (decode-universal-time time-value)
-      (declare (ignore dow dst))
+        (decode-universal-time time-value)
+      (declare (ignore dow))
       (format nil "~4,'0D-~2,'0D-~2,'0DT~2,'0D:~2,'0D:~2,'0D~:[~*~;~A~]"
               year month day hour minute second
-              include-timezone-p (format-iso8601-timezone zone)))))
+              include-timezone-p (format-iso8601-timezone (if dst
+                                                              (+ zone 1)
+                                                              zone))))))
 
 (defmethod emacs-inspect ((i integer))
           (append





More information about the slime-cvs mailing list