]> diplodocus.org Git - nmh/commit
Patch for mhical to support "BYDAY=-1SU"-type RRULEs.
authorConrad Hughes <biz_nmh_workers@xrad.org>
Tue, 14 Jan 2020 10:01:46 +0000 (10:01 +0000)
committerDavid Levine <levinedl@acm.org>
Mon, 20 Jan 2020 18:52:05 +0000 (13:52 -0500)
commit832096365a1519eadbaad02646616359e9870513
tree7c0f4cfa1f7e25e80a5a4282c02c67820c9af922
parent23816efd3e8e294e8f1c1ce811ac3a1cd15d334e
Patch for mhical to support "BYDAY=-1SU"-type RRULEs.

Notes:

- Added dmlastday() function to dtime.c, to obtain last day of month.
  Minor modifications to other parts here to reuse code.

- Modified rrule_clock() in datetime.c to handle negative BYDAY
  correctly.

- Added a couple of tests.

- Mainly this is to scratch an itch since UK timezone history makes
  heavy use of BYDAY=-1SU-type RRULEs, and the resultant complaints
  are annoying.  I had a brief look at "properly" extending
  icalparse.y, but I kindof think any serious extension of mhical
  should really instead adopt libical?
sbr/datetime.c
sbr/dtime.c
sbr/dtime.h
test/mhical/test-mhical