[Issue 13533] std.datetime should support custom parsing and formatting functions

via Digitalmars-d-bugs digitalmars-d-bugs at puremagic.com
Wed Oct 22 06:57:57 PDT 2014


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

Martin Nowak <code at dawg.eu> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
            Summary|DateTime.fromISOExtString   |std.datetime should support
                   |should also accept space    |custom parsing and
                   |separator (instead of 'T')  |formatting functions

--- Comment #4 from Martin Nowak <code at dawg.eu> ---
Renamed the enhancement request.

For all the common types DateTime, TimeOfDay, Date, SysTime there should be
parse and format functions that accept custom format strings.

It would make sense to use a syntax similar to strftime and strptime and also
have a look at other programming languages.

If it can be used for optimization then format strings as template argument
might make sense. If well done those could even replace the hand-written
from*String/to*String methods.

Is there a specific reason that SimpleTimeZone.fromISOString isn't public?

--


More information about the Digitalmars-d-bugs mailing list