On Tue, Nov 15, 2011 at 11:10 AM, Brian Fraser <frase...@gmail.com> wrote:
> No. Just, no.

On this list, I think that counts as high praise.  Thanks!

> Read this:
> http://stackoverflow.com/questions/4077896/perl-or-python-convert-date-from-dd-mm-yyyy-to-yyyy-mm-dd/4078817#4078817

Err, which part?  tchrist is an expert on dealing with unicode in
various languages/regex engines and in real-world "text" data, but I
think he's overreaching there; I don't expect my date strings to
include non-ASCII digits.  I can see some software butchering - into a
non-ASCII dash character, but I'd tend to treat fixing that as a
separate problem.  (Though that was actually a motivation in having my
regex looking for /, not -.)

> Then forget about using regexen and find a module to do it for you.
> Regexp::Common::time is pretty nice, albeit slow if you are doing millions
> of validations.
> (But in the spirit of this list, sure, that's cool. Would be cooler if you
> could abstract it using (?(DEFINE)) :)

Meh.  I think that would only obfuscate it.

Reply via email to