changeset 7248:48ef5c3465ae

(solar-degrees-to-hours, solar-hours-to-days): Force floating result. (sunrise-sunset): Don't alter calendar-daylight-savings-starts and calendar-daylight-savings-ends.
author Richard M. Stallman <rms@gnu.org>
date Sun, 01 May 1994 07:39:02 +0000
parents bead6db0bbf2
children 876b3518fa78
files lisp/calendar/solar.el
diffstat 1 files changed, 8 insertions(+), 6 deletions(-) [+]
line wrap: on
line diff
--- a/lisp/calendar/solar.el	Sun May 01 07:34:23 1994 +0000
+++ b/lisp/calendar/solar.el	Sun May 01 07:39:02 1994 +0000
@@ -183,10 +183,10 @@
   "Eccentricity of orbit of the earth around the sun.")
 
 (defmacro solar-degrees-to-hours (deg)
-  (list '/ deg 15))
+  (list '/ deg 15.0))
 
 (defmacro solar-hours-to-days (hour)
-  (list '/ hour 24))
+  (list '/ hour 24.0))
 
 (defun solar-longitude-of-sun (day)
   "Longitude of the sun at DAY in the year."
@@ -429,10 +429,12 @@
                  ((< calendar-time-zone 0)
                      (format "UTC%dmin" calendar-time-zone))
                  (t  (format "UTC+%dmin" calendar-time-zone)))))
-        (calendar-daylight-savings-starts
-         (if (< arg 16) calendar-daylight-savings-starts))
-        (calendar-daylight-savings-ends
-         (if (< arg 16) calendar-daylight-savings-ends))
+;;   Use outer context values always, unless you're going to prompt for
+;;   the values to use.  PKH
+;;        (calendar-daylight-savings-starts
+;;         (if (< arg 16) calendar-daylight-savings-starts))
+;;        (calendar-daylight-savings-ends
+;;         (if (< arg 16) calendar-daylight-savings-ends))
         (date (if (< arg 4) (calendar-current-date) (calendar-read-date)))
         (date-string (calendar-date-string date t))
         (time-string (solar-sunrise-sunset date))