QDate range extended

David Jarvie lists at astrojar.org.uk
Wed Jun 14 13:10:00 BST 2006


On Wednesday 14 June 2006 12:37, Thiago Macieira wrote:
>David Jarvie wrote:
>>Surely the solution to Jason's needs is to make the Julian day a signed
>> value.
>[...]
>> except for the need to replace zero with 0x8000000 or 0x7FFFFFFF as the 
>>indicator of an invalid date.
>
>Can't do that. The isNull that tests for jd == 0 to say it's invalid is an 
>inline function. There's no way to change that before Qt 5.0. Therefore, 
>Julian Day 0 must be outside the valid date range.
>
>I am not going to create a discontiguous date range (i.e., a range with a 
>hole in the middle).

Too bad - a missed opportunity for Trolltech to introduce the splendid idea of "the date 
which didn't exist". Perhaps, in line with the theme of red giants etc., it could be 
termed "black hole day", which might make the concept attractive for use in an astronomical 
program like KStars? ;-)

--
David Jarvie.
KAlarm author & maintainer.
http://www.astrojar.org.uk/linux/kalarm.html




More information about the kde-core-devel mailing list