digitalmars.D.learn - std.date / std.datetime
- Richard Chamberlain (14/14) Jan 18 2011 Hello,
- Jonathan M Davis (4/21) Jan 18 2011 std.datetime is currently in Phobos' svn repository and will be in the n...
- %fil (8/8) Jan 18 2011 Hi Jonathan,
- Jonathan M Davis (9/16) Jan 18 2011 I don't know. The last release was about a month ago, and the one before...
- Richard Chamberlain (3/24) Jan 18 2011 Thanks Jonathan.
- Russel Winder (23/31) Jan 18 2011 that=20
- Jonathan M Davis (14/36) Jan 18 2011 There has been discussion of D needing some sort of package management s...
- torhu (4/16) Jan 18 2011 You could always use the C functions, if you import core.stdc.time. The...
Hello, I'm in the process of learning D, and to do so I'm converting some older code. I need to print out the current local date and time, which is causing some difficulties because std.date doesn't seem adequate in this respect. I understand there is soon to be a replacement, std.datetime, which I suspect will be much easier. When are we likely to see a new release which includes std.datetime? If not relatively soon I presume the easiest thing to do is to download it myself and recompile the phobos library to include it. In which case there seems to be already a std.datetime with different functionality, is this used elsewhere in phobos? i.e. if I replace it with the new std.datetime is that OK? Many thanks, Richard
Jan 18 2011
On Tuesday 18 January 2011 03:34:06 Richard Chamberlain wrote:Hello, I'm in the process of learning D, and to do so I'm converting some older code. I need to print out the current local date and time, which is causing some difficulties because std.date doesn't seem adequate in this respect. I understand there is soon to be a replacement, std.datetime, which I suspect will be much easier. When are we likely to see a new release which includes std.datetime? If not relatively soon I presume the easiest thing to do is to download it myself and recompile the phobos library to include it. In which case there seems to be already a std.datetime with different functionality, is this used elsewhere in phobos? i.e. if I replace it with the new std.datetime is that OK?std.datetime is currently in Phobos' svn repository and will be in the next release. - Jonathan M Davis
Jan 18 2011
Hi Jonathan, I'm also stuck with the existing std.date and would want to try out your new module std.datetime. Do you have any sense when the next release of Phobos is going to be? If not, what is the procedure to get a "development snapshot" of the latest version of Phobos installed? thanks, fil
Jan 18 2011
On Tuesday 18 January 2011 04:15:20 %fil wrote:Hi Jonathan, I'm also stuck with the existing std.date and would want to try out your new module std.datetime. Do you have any sense when the next release of Phobos is going to be?I don't know. The last release was about a month ago, and the one before that was about a month and a half before that. I'm not aware of there being any hard and fast rules or plan about when releases are done. However, they tend to be a month or two apart.If not, what is the procedure to get a "development snapshot" of the latest version of Phobos installed?The latest code can be found here: http://www.dsource.org/projects/phobos However, you're going to have to have the latest druntime as well: http://www.dsource.org/projects/druntime - Jonathan M Davis
Jan 18 2011
On 2011-01-18 16:34:53 +0000, Jonathan M Davis said:On Tuesday 18 January 2011 04:15:20 %fil wrote:Thanks Jonathan. I think I'll hang around for the official update.Hi Jonathan, I'm also stuck with the existing std.date and would want to try out your new module std.datetime. Do you have any sense when the next release of Phobos is going to be?I don't know. The last release was about a month ago, and the one before that was about a month and a half before that. I'm not aware of there being any hard and fast rules or plan about when releases are done. However, they tend to be a month or two apart.If not, what is the procedure to get a "development snapshot" of the latest version of Phobos installed?The latest code can be found here: http://www.dsource.org/projects/phobos However, you're going to have to have the latest druntime as well: http://www.dsource.org/projects/druntime - Jonathan M Davis
Jan 18 2011
On Tue, 2011-01-18 at 08:34 -0800, Jonathan M Davis wrote: [ . . . ]I don't know. The last release was about a month ago, and the one before =that=20was about a month and a half before that. I'm not aware of there being an=y hard=20and fast rules or plan about when releases are done. However, they tend t=o be a=20month or two apart.[ . . . ]The latest code can be found here: http://www.dsource.org/projects/phobos =20 However, you're going to have to have the latest druntime as well: =20 http://www.dsource.org/projects/druntimeMight it be worth putting in some infrastructure whereby people can use a distributed DMD or GDC but have a current snapshot or perhaps latest build of Phobos (where there is consistency between DMD/GDC on the one hand and Phobos on the other). This is actually one thing Go does supremely well, you can pull the Mercurial snapshot and build the entire system within about 5 minutes. It makes it very easy to test new stuff.=20 --=20 Russel. =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D Dr Russel Winder t: +44 20 7585 2200 voip: sip:russel.winder ekiga.n= et 41 Buckmaster Road m: +44 7770 465 077 xmpp: russel russel.org.uk London SW11 1EN, UK w: www.russel.org.uk skype: russel_winder
Jan 18 2011
On Tuesday, January 18, 2011 09:18:33 Russel Winder wrote:On Tue, 2011-01-18 at 08:34 -0800, Jonathan M Davis wrote: [ . . . ]There has been discussion of D needing some sort of package management system. Perhaps that would deal with that issue. And maybe with dmd, druntime, and Phobos being moved over to git and github (which is currently being worked on) will make that easier. I don't know. However, I think that the focus of the dev team overall has been more on getting done than making it easier for people to get current development snapshots or know exactly what's going on with development at the moment. That's not to say that such things shouldn't be improved or that the dev team doesn't want to improve them, but there have been other priorities which have taken precedence. There's also a strong tendency for things to get done because someone wants them done and takes the time to do them, and if there's no one who's motivated enough to do something, then it often doesn't get done in a timely manner. - Jonathan M DavisI don't know. The last release was about a month ago, and the one before that was about a month and a half before that. I'm not aware of there being any hard and fast rules or plan about when releases are done. However, they tend to be a month or two apart.[ . . . ]The latest code can be found here: http://www.dsource.org/projects/phobos However, you're going to have to have the latest druntime as well: http://www.dsource.org/projects/druntimeMight it be worth putting in some infrastructure whereby people can use a distributed DMD or GDC but have a current snapshot or perhaps latest build of Phobos (where there is consistency between DMD/GDC on the one hand and Phobos on the other). This is actually one thing Go does supremely well, you can pull the Mercurial snapshot and build the entire system within about 5 minutes. It makes it very easy to test new stuff.
Jan 18 2011
On 18.01.2011 12:34, Richard Chamberlain wrote:Hello, I'm in the process of learning D, and to do so I'm converting some older code. I need to print out the current local date and time, which is causing some difficulties because std.date doesn't seem adequate in this respect. I understand there is soon to be a replacement, std.datetime, which I suspect will be much easier. When are we likely to see a new release which includes std.datetime? If not relatively soon I presume the easiest thing to do is to download it myself and recompile the phobos library to include it. In which case there seems to be already a std.datetime with different functionality, is this used elsewhere in phobos? i.e. if I replace it with the new std.datetime is that OK?You could always use the C functions, if you import core.stdc.time. The ctime and strftime functions should do the trick. http://cplusplus.com/reference/clibrary/ctime/
Jan 18 2011