[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Emacs-diffs] master 6cfda69 1/2: Add support for dealing with decod
Re: [Emacs-diffs] master 6cfda69 1/2: Add support for dealing with decoded time structures
Thu, 01 Aug 2019 13:21:21 +0200
Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)
"Basil L. Contovounesios" <address@hidden> writes:
> While having a second look at this I noticed timezone-leap-year-p is
> identical to date-leap-year-p. Should the former become an obsolete
> alias of the latter?
Ah, basically all these functions in the timezone package have the
functions that I added to time-date while writing iso8601.
;; Partly copied from Calendar program by Edward M. Reingold.
;; Thanks a lot.
(defun timezone-last-day-of-month (month year)
(defun timezone-leap-year-p (year)
(defun timezone-day-number (month day year)
I don't think "timezone" is a logical naming for these, so I think they
should be made into obsolete aliases for the time-date functions.
(defun timezone-absolute-from-gregorian (month day year)
And digging even further back, there's `timezone-parse-date', which
basically tries to parse anything even remotely time-like in a string
(and has exactly one in-tree user, nnrss.el). Hm... Well, it pretty
much looks like almost all the functions in that file have no or very
few in-tree usages, and there are more modern counterparts to all of
them, I think.
I'm guessing that we've reached this state of affairs because newer
time/date handling functions have been added over the years, and that
the "timezone" prefix isn't an obvious place to look for these things,
so any usages over the years have gone away.
I think making (almost) all of them obsolete and adjusting the callers
(if any) is probably the way to go.
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no