[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [bug-gawk] gawk with dates before 1970

From: Eli Zaretskii
Subject: Re: [bug-gawk] gawk with dates before 1970
Date: Tue, 14 Apr 2015 17:47:24 +0300

> From: Aharon Robbins <address@hidden>
> Date: Tue, 14 Apr 2015 15:56:30 +0300
> Cc: address@hidden, address@hidden, address@hidden
> > 2. There's a general question of how to handle the case where the
> > floating-point timestamp argument cannot be converted to a time_t that
> > preserves its value.  This goes beyond the signed/unsigned concern that
> > Eli raised.
> This is a general issue in awk/gawk.  At some point the user has to
> know what s/he is doing, and I think this is one of those points.

I don't think we want to burden users of Gawk with intimate knowledge
about the details of time functions on their system.  It is a simple
test to see that the FP value fits into time_t limitations, so I don't
see why not add that test, right where we test for negative values

IOW, it's a simple generalization of the current test: instead of
looking only at the sign, make sure the value is between the minimum
and the maximum allowed limits, and if not, yell bloody murder.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]