[tz] Troll in the long term
zefram at fysh.org
Tue Mar 25 15:15:58 UTC 2014
Arthur David Olson wrote:
>An interesting long-term exercise: extend (once again) the zic-produced
>POSIX-like time zone string format to cover Troll.
Not really an appealing proposition. The 400-year hack is serviceable.
But if you want to go this route, I suggest abandoning the concept of
a single DST offset and initialism in favour of attaching them to each
transition rule. Say, for Troll,
Rules: if there are more than two transitions per annum, the DST offset
and initialism must be omitted from the base part of the TZ spec.
There may be any number of transition rules. A rule may have appended
"=", initialism, and offset: the initialism and offset (from UT) have the
same syntax as in the base part. A rule with no "=" describes a return to
the standard offset and initialism (from the base part), unless it's the
first of the exactly two rules in an existing-format spec that specifies
a DST initialism in the base part. The zone is reckoned to be "on DST"
iff the current offset differs from the standard offset specified in
the base part.
As a bonus, this could express a permanently-on-DST zone, by using a
fake transition to DST and no transition back:
Possible refinement: allow the isdst flag to be explicitly stated
with each initialism/offset pair. That would allow a permanently-DST
arrangement to be specified more directly, but more importantly would
allow for Troll on CET to be reckoned not-DST. Currently zic itself
determines isdst based on matching the standard offset, and would need
an addition to take an explicit flag in its input (presumably in the
More information about the tz