Re: dash: read does not ignore trailing spaces

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

 



2015-12-03 22:43:39 +0100, Martijn Dekker:
> Stephane Chazelas schreef op 03-12-15 om 22:17:
> > It's meant to split into "a" and "b", not "a", "b" and "". As
> > ":" is meant to be treated as a *delimiter* or *terminator*.
> 
> That was my interpretation of the standard, too. So I reported this as a
> bug to author of yash, but he reads the standard differently and came up
> with a good argument for that. See:
> 
> https://osdn.jp/ticket/browse.php?group_id=3863&tid=35283#comment:3863:35283:1435293070
> 
> Summarising: POSIX states that "each occurrence in the input of an IFS
> character that is not IFS white space, along with any adjacent IFS white
> space, shall delimit a field". This *may* be interpreted to read that a
> final non-whitespace IFS character denotes an empty final field, because
> otherwise that final character wouldn't be delimiting any field, but
> only terminating one. It's pretty ambiguous, though.
[...]

I agree the spec is not very clear
http://thread.gmane.org/gmane.comp.shells.bash.bugs/4825
http://thread.gmane.org/gmane.comp.shells.bash.bugs/15768

But see this interpretation:
https://standards.ieee.org/findstds/interps/1003.1-2001/1003.1-2001-98.html

I can't find the austin-group discussions, but I'm pretty sure
I've seen several and Chet is refering to one from 2005 over
there.

-- 
Stephane
--
To unsubscribe from this list: send the line "unsubscribe dash" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [LARTC]     [Bugtraq]     [Yosemite Forum]     [Photo]

  Powered by Linux