2014-12-11 22:00 GMT+01:00 MRAB email@example.com:
On 2014-12-11 18:33, Skip Montanaro wrote:
there are likely to be situations where the caller assumes it generates a six-digit string. I did a little poking around. It seems like "%N" isn't used.
Could the number of digits be specified? You could have "%9f" for
nanoseconds, "%3f" for milliseconds, etc. The default would be 6 microseconds for backwards compatibility.
Ruby does that, but use %9N. (a plain %N consume 9 digits by default).
GNU date also use %N, but doesn't allow to specify the number of digits to consume.