[phobos] datetime review

Jonathan M Davis jmdavisProg at gmx.com
Fri Oct 8 17:01:11 PDT 2010


I should probably add that the seven modules aren't exactly equal in size. In 
particular datetime.all only has its module documentation and public imports for 
all of the other modules, and datetime.other is quite small. I didn't 
necessarily split the code into modules in the best manner. I split it more on 
concepts than the amount of code in them (so datetime.timepoint probably has 
close to half of the code in it). I'm open to suggestions if someone has a 
better way to split the code up. Ideally, it would all be in one module, but it 
was too much for one.

Also, as much as there is, a large portion of it is unit tests and 
documentation. There's definitely more unit tests than normal code, and there 
might be more documentation than normal code.

One point that may need to be improved is the module documentation so that it's 
more obvious exactly what you need to just get the time and print it out or 
whatever the insanely simple operations are that would be typical in your 
average program that does little with the time. I am afraid that it is a bit 
like std.algorithm in that it's quite easy to use but a bit overwhelming to look 
at so that you _think_ that it's hard to use, even though it really isn't. I do 
have quite a few examples it the code though, and I hope that the documentation 
is generally clear enough. I tried to make it so that it was, but it really 
needs to have people who aren't familiar with it judge it at this point.

- Jonathan M Davis


More information about the phobos mailing list