chickadee » srfi-19 » date-adjust

date-adjust DATE AMOUNT DATE-KEY #!optional CLOCK-TYPEprocedure

Returns a new date, the DATE adjusted by the AMOUNT of DATE-KEY.

AMOUNT is an integer.

DATE-KEY is either 'years, 'quarters, 'months, 'days, 'hours, 'minutes, 'seconds, 'milliseconds, 'microseconds, or 'nanoseconds.

If the day of the month of DATE is greater than the number of days in the final month, the day of the month will change to the last day in the final month.

Adjusting a time DATE-KEY (ex: 'hours) follows the semantics of date-add-duration.