thyme icon indicating copy to clipboard operation
thyme copied to clipboard

Improvement request: documentation improvements

Open axman6 opened this issue 8 years ago • 1 comments

Many of the functions in at least Data.Thyme.Time.Core lack any documentation, for example

dayOfYearToMonthAndDay :: Bool -> DayOfYear -> (Month, DayOfMonth)

gives no guidance to what the Bool represents (it's only when looking at the code that you find it specified if the DayOfYear is part of a leap year). In many cases it's pretty clear what the meaning is, but when both

addGregorianYearsClip :: Years -> Day -> Day

and

addGregorianYearsRollover :: Years -> Day -> Day

exist, some documentation is needed to explain exactly what the difference is (what is being clipped or rolled over? Is this also for the case where you're adding years spanning a leap year?)

axman6 avatar Mar 02 '17 03:03 axman6

I'd also suggest adding examples to the format code so it's easy to see what output to expect.

jml avatar Mar 09 '17 15:03 jml