GNU bug report logs - #11115
linux date arithmetic

Previous Next

Package: coreutils;

Reported by: Stefan Karamuz <stefan <at> karamuz.pl>

Date: Wed, 28 Mar 2012 17:59:02 UTC

Severity: normal

Tags: notabug

Done: Assaf Gordon <assafgordon <at> gmail.com>

Bug is archived. No further changes may be made.

Full log


Message #23 received at 11115 <at> debbugs.gnu.org (full text, mbox):

From: Bruno Haible <bruno <at> clisp.org>
To: Eric Blake <eblake <at> redhat.com>
Cc: bug-gnulib <at> gnu.org, 11115 <at> debbugs.gnu.org,
	Stefan Karamuz <stefan <at> karamuz.pl>
Subject: Re: bug#11115: linux date arithmetic
Date: Thu, 29 Mar 2012 11:21:40 +0200
Eric Blake wrote:
> > "10:38 minute" or "12:38 minute" is not a time designation I have ever heard
> > in spoken nor written English.
> 
> True, 'minute' in isolation, without a 'plus one' qualifier, is unusual;
> but we have to continue to parse it in isolation since scripts may now
> be relying on it.

No, we don't have to support syntaxes that are not documented and that
were only accidentally supported. Scripts may rely on documented features,
not on undocumented ones.

The doc in parse-datetime.texi explains that the literal word 'minute'
occurs only as part of a displacement. Thus it has to follow a number.
It can not occur after a literal time ("10:38" or "12:38") nor after a
time with displacement ("11:38 +1").

IMO spaces are irrelevant in this discussion.

> It's just that getdate.y is a hairy mess
> to properly implement that change without breaking other worthwhile
> constructs

I would remove the "tMINUTE_UNIT" alternative from 'relunit' and move it
instead to the rules that invoke 'relunit' and that need this alternative.

Bruno





This bug report was last modified 6 years and 218 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.