Re: policy around 'wontfix' bug tag
On 2018-02-06 13:48:19 +0100, Vincent Lefevre wrote:
> This is completely crazy:
>
> zira% date +%Y-%m-%d -d '2003-09-01 1 day ago + 1 month'
> 2003-09-30
> zira% date +%Y-%m-%d -d '2003-09-01 1 day ago'
> 2003-08-31
> zira% date +%Y-%m-%d -d '2003-08-31 + 1 month'
> 2003-10-01
>
> So, while '2003-09-01 1 day ago' gives 2003-08-31, the following
> are not equivalent:
> * '2003-09-01 1 day ago + 1 month'
> * '2003-08-31 + 1 month'
>
> Where is the logic behind that?
Other ones:
zira% date +%Y-%m-%d -d '2003-02-01 - 1 month'
2003-01-01
zira% date +%Y-%m-%d -d '2003-02-01 - 31 days'
2003-01-01
zira% date +%Y-%m-%d -d '2003-02-01 - 31 days + 1 month'
2003-01-29
zira% date +%Y-%m-%d -d '2003-02-01 - 1 month + 1 month'
2003-02-01
--
Vincent Lefèvre <vincent@vinc17.net> - Web: <https://www.vinc17.net/>
100% accessible validated (X)HTML - Blog: <https://www.vinc17.net/blog/>
Work: CR INRIA - computer arithmetic / AriC project (LIP, ENS-Lyon)
Reply to: