[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: test -lt inconsistent about white space
From: |
Chet Ramey |
Subject: |
Re: test -lt inconsistent about white space |
Date: |
Mon, 30 Oct 2023 10:54:41 -0400 |
User-agent: |
Mozilla Thunderbird |
On 10/28/23 3:08 PM, Paul Eggert wrote:
The problem occurs because strtoimax accepts all forms of leading
whitespace, whereas Bash accepts only space and tab after the integer. This
is inconsistent: Bash should treat trailing whitespace the same way it
treats leading whitespace, and should accept all of doit's 'test' commands,
as Dash does.
I'm not sure it was a good idea to have strtoimax accept leading vertical
whitespace, but as long as it does, we might as well accept the same set
of whitespace characters following the digit string.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU chet@case.edu http://tiswww.cwru.edu/~chet/
Re: test -lt inconsistent about white space, Martin D Kealey, 2023/10/29
Re: test -lt inconsistent about white space,
Chet Ramey <=