Re: gdate integration

Quoting Havoc Pennington (

> > Please use 0..6 for the valid days and -1 for the bad day. This way,
> > one can work with modulo on week days (well, more easily :-) OTOH,
> > months from 1 to 12 look more "natural" than from 0 to 11 :-/
> I think this is too inconsistent with the rest of GDate... right now all
> values are unsigned, with 0 the invalid value... this means g_date_clear
> just zeroes the struct. If you did this then one of the values would be
> signed, and 0 would be a valid value for it, and it would be sort of
> hackish I think.

You can also fill the structure with -1 :-) But I agree with that
days and months from 0 are "unnatural" (but the whole time/date thing
is "unmathematical" :-)

Dipl. Inf. (FH) Aaron "Optimizer" Digulla     Assistent im BIKS Labor, FB WI
"(to) optimize: Make a program faster by      FH Konstanz, Brauneggerstr. 55
improving the algorithms rather than by       Tel:+49-7531-206-514
buying a faster machine."                     EMail:

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]