develooper Front page | perl.perl5.porters | Postings from December 2012

POSIX wrapper for strptime()

Thread Next
Paul LeoNerd Evans
December 19, 2012 22:42
POSIX wrapper for strptime()
Message ID:

anyone still object to this going in?

I recall last time the objections came down to the fact that nobody else
other than me appeared to want it, and something about "UTF-8 and
locales is hard". Which basically comes down to the problem that we Do
Not Know if the locale is going to give us UTF-8 strings or not, so we
can't know what will be the correct thing to do.

But that isn't a strptime()-specific problem and happens all over the
place and we don't appear to care.

I think I was just the victim of being overly-cautious about adding this
one function, and any objections to it could equally well be made about
half a dozen other functions already in POSIX.{pm,xs} that should
arguably removed, if strptime() is to be rejected for the same reasons.

So, given I've just this second had to explain to something like the
10th person on #perl/Freenode, the fact that "sorry, core has no
strptime() you can use for this, but try the broken POSIX::strptime
module off CPAN provided you are on Linux", I would instead prefer that
we actually get this into core sometime...

.. maybe next year?

Paul "LeoNerd" Evans
ICQ# 4135350       |  Registered Linux# 179460

Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About