[tz] Relative to Beginning of Month or to End

Paul Eggert eggert at cs.ucla.edu
Fri Jul 6 18:01:05 UTC 2012


On 07/06/2012 08:55 AM, Marvel, Jim (CPCOE) wrote:
> Did a zdump.  How to tell if timezone DST rules indicate counting
> relative to beginning of month ("2nd Tuesday")
> or to end of month (last Sunday for example).
> Does this info live in the source code?

That info does not live in the data given to zdump.
It does live in the original source for that
data, i.e., the source fed to zic.  But zic
discards it and it is not present in zic's
output (i.e., in zdump's input).

There is software that reverse-engineers the zic
output and attempts to infer that info.  It's not
perfect, but it works fairly well in practice, at
least for future time stamps where there is typically
only one rule into the indefinite future.  See
the function calendar-time-zone-daylight-rules
in GNU Emacs; there may be other examples but this
is the one I'm familiar with.


More information about the tz mailing list