-
-
Notifications
You must be signed in to change notification settings - Fork 8
Description
Migrated from rt.cpan.org #85771 (status was 'new')
Requestors:
From kwilliams@cpan.org (@kenahoo) on 2013-05-31 18:04:39:
There's a %[number]N field for nanoseconds or microseconds or whatever, but if you have a number of seconds in decimal format with a variable number of decimal places (e.g. 12:34:56.789 PM), it can't be parsed directly. The workaround would be to scan through the data, find the maximum number of decimal places, pad to that length, then use %[number]N. This wouldn't be easy because the "scan through the data" part could require the user to write some pretty fancy parsing machinery.
One solution could be to allow a dot in the %S field, a la %.S . Not sure whether there's a precedent for that or not in other parsing libraries.