On Tue, Jan 30, 2001 at 02:09:32PM -0200, Branden wrote:
> Jarkko Hietaniemi wrote:
> > I guess it's part of the can of sub-second worms: if we do sleep(),
> > people will ask why don't we do time() and alarm(), too. sleep() and
> > alarm() we could get away with more easily, but changing time() to do
> > subsecond granularity would be A Bad Thing for backward compatibility.
> > Think of generated filenames, or various logs with timestamps. We can
> > (hopefully) do a magical p52p6 translator, but fixing the existing
> > data is a tad harder.
>
>
> I see no trouble in time returning a float value. p52p6 could translate
> time() to int(time()) and everything should work ok. Anyway, time is
As I said the problem isn't the p52p6 doing that kind of transformation.
The problem is someone familiar with perl5 writing code in perl6:
if (my $fh = open(">/tmp/$$".time())) {
and later something crashing and burning because some other place expects
to find a filename of the form /^\d+\d+$/, or someone printing into log files
like this
print LOG time() . ": gorkulator borked. Please investigate."
and someone splitting on /\./, etc.
> probably gonna change in perl6, since it's UNIX-based now and i think
> we no longer have to know how many seconds have passed since mid-night
> january 1st 1970, do we?
Some sort of less C/UNIX-centric way would be nice, yes.
--
$jhi++; # http://www.iki.fi/jhi/
# There is this special biologist word we use for 'stable'.
# It is 'dead'. -- Jack Cohen