[Issue 18552] std.datetime.date.Date strips year int argument to short

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun Mar 4 03:23:11 UTC 2018


https://issues.dlang.org/show_bug.cgi?id=18552

--- Comment #2 from feklushkin.denis at gmail.com ---
> What is the use case where this matters?

RDBMSes (at least Postgres) supports int type of year. With restrictions
associated with Julian day (4713 BC boundary) it can represent up to 294276 AD.

When converting test values to and from Postgres I found mismatch for such big
numbers.

> The documenattion makes it pretty clear that Date does not support values beyond what a short can hold

Does not overrides necessity of assert, at least

--


More information about the Digitalmars-d-bugs mailing list