Limitations |

## Gregorian Calendar

The Gregorian calendar has been adopted in most western countries since the 16th century (e.g. since 20 December 1582 in France) with possible disruptions (e.g. French Revolutionary calendar used from 24 November 1793 to 31 December 1805). The Gobo Eiffel Time Library does not take this into account and considers that the Gregorian calendar was always in use (even at the time of dinosaurs) and will always be in the future.

## Leap Seconds

The International Earth Rotation Service periodically uses leap seconds to keep UTC to within 0.9 second of UT1 (which measures the true angular orientation of the earth in space). There were no leap seconds before 1972 because the official mechanism accounting for the discrepancy between atomic time and the earth's rotation did not exist until the early 1970s. The Gobo Eiffel Time Library does not support leap seconds.

## Time Limits

The maximum precision of the current implementation of `DT_TIME` is the millisecond. Although the public interface of `DT_TIME` has four fields (`hour`, `minute`, `second` and `millisecond`), its internal state is compacted into a single integer. Therefore in order for `DT_TIME` to work, your Eiffel compiler should implement `INTEGER` with at least 32 bits so that it can hold the number of milliseconds in one day (i.e. 86,400,000).

Some clients, such as classes which need to store and retrieve time objects efficiently, may want to have access to the compaction integer called `storage`. They can do so by simply inheriting from `DT_TIME_HANDLER`. The creation procedure `make_from_storage` is also available to descendants of `DT_TIME_HANDLER`.

## Date Limits

Although the public interface of `DT_DATE` has three fields (`year`, `month` and `day`), its internal state is compacted into a single integer. Therefore in order for `DT_DATE` to work, your Eiffel compiler should implement `INTEGER` with at least 32 bits so that it can hold nowadays dates. The first five right-most bits are used to store the day, the next four bits to store the month. Considering that your Eiffel compiler implements `INTEGER` with 32 bits, this means that there are 23 bits left for the year. In such case the minimum date supported would be 1 January -4,194,305, and the maximum date would be 31 December 4,194,304.

Some clients, such as classes which need to store and retrieve date objects efficiently, may want to have access to the compaction integer called `storage`. They can do so by simply inheriting from `DT_DATE_HANDLER`. The creation procedure `make_from_storage` is also available to descendants of `DT_DATE_HANDLER`.

## Date Time Limits

`DT_DATE_TIME` has of course the same implementation constraints as `DT_DATE` and `DT_TIME`. A date/time object has in fact two compaction integers, `date_storage` and `time_storage`, and clients should inherit from `DT_DATE_TIME_HANDLER` in order to have access to them.