On 6/23/17 10:35 PM, Robert Elz wrote:
> Date:Fri, 23 Jun 2017 11:39:45 -0400
> From:Greg Wooledge
> Message-ID: <20170623153945.ga4...@eeg.ccf.org>
>
> | That's what I always thought too, but if commonly used shells like
> | dash can't even agree on this, then I
On Sat, Jun 24, 2017 at 09:10:34PM +0700, Robert Elz wrote:
[...]
> The bugs in various implementations cause problems, yes, dealing with
> someone else's mistakes (and especially doing it in a way that things
> still work when the bugs get fixed) can be difficult.
>
> But the rules, no, the rules
Date:Sat, 24 Jun 2017 07:59:25 -0500
From:Eduardo =?utf-8?Q?A=2E_Bustamante_L=C3=B3pez?=
Message-ID: <20170624125925.7vnb4kk35gh3obbk@debian>
| I think we can all agree that the rules (and bugs) around
| the expansion of $* are too complex.
The bugs in various i
On Sat, Jun 24, 2017 at 09:35:34AM +0700, Robert Elz wrote:
[...]
> In cases where IFS is not a null string, the broken implementations mostly
> tend to work OK (sometimes perhaps only by a fluke), and even more work
> properly if IFS has its default value or something similar, that is
> where IFS[
Date:Fri, 23 Jun 2017 11:39:45 -0400
From:Greg Wooledge
Message-ID: <20170623153945.ga4...@eeg.ccf.org>
| That's what I always thought too, but if commonly used shells like
| dash can't even agree on this, then I simply upgrade my response level
| from "bad prac
On 6/23/17 11:27 AM, Robert Elz wrote:
> Date:Thu, 22 Jun 2017 07:51:12 -0400
> From:Greg Wooledge
> Message-ID: <20170622115111.gq22...@eeg.ccf.org>
>
>
> | $ dash
> | $ set -- a b
> | $ IFS=
> | $ args $*
> | 1 args:
>
> That is simply broken. Always h
On Fri, Jun 23, 2017 at 10:27:44PM +0700, Robert Elz wrote:
> $* is just $1 $2 ... (for as many params as set) as separate words.
That's what I always thought too, but if commonly used shells like
dash can't even agree on this, then I simply upgrade my response level
from "bad practice" to "comple
Date:Thu, 22 Jun 2017 07:51:12 -0400
From:Greg Wooledge
Message-ID: <20170622115111.gq22...@eeg.ccf.org>
| $ dash
| $ set -- a b
| $ IFS=
| $ args $*
| 1 args:
That is simply broken. Always has been, whatever mistakes were
in the wording posix used to us
On Thu, Jun 22, 2017 at 7:51 AM, Greg Wooledge wrote:
> On Wed, Jun 21, 2017 at 10:30:22PM -0400, Chet Ramey wrote:
>
> OK, going forward, I am officially considering any use of unquoted $*
> or $@ in a script to be a BUG, an invocation of undefined behavior,
> not acceptable, no excuses.
>
>
I t
On Wed, Jun 21, 2017 at 10:30:22PM -0400, Chet Ramey wrote:
> However, not all shells were consistent in their interpretation of the
> Posix rules. For instance, dash, which bills itself as being completely
> Posix conformant, produces 1 for that case (and expands to "ab"). The
> Bourne shell (SVR
On 6/21/17 6:01 PM, Kevin Brodsky wrote:
> On 21/06/2017 20:29, Chet Ramey wrote:
>> On 6/21/17 2:43 PM, Kevin Brodsky wrote:
>>
>>> That is also my reading of POSIX (and that's more or less what Bash's
>>> manpage says as well), but it doesn't seem to be the case (even in <=4.2):
>> That's a relat
On 21/06/2017 20:29, Chet Ramey wrote:
> On 6/21/17 2:43 PM, Kevin Brodsky wrote:
>
>> That is also my reading of POSIX (and that's more or less what Bash's
>> manpage says as well), but it doesn't seem to be the case (even in <=4.2):
> That's a relatively new requirement. The portion of the relev
On 6/21/17 2:43 PM, Kevin Brodsky wrote:
> That is also my reading of POSIX (and that's more or less what Bash's
> manpage says as well), but it doesn't seem to be the case (even in <=4.2):
That's a relatively new requirement. The portion of the relevant sentence
that reads "initially producing
On 21/06/2017 14:54, Chet Ramey wrote:
> On 6/20/17 1:33 AM, Eduardo A. Bustamante López wrote:
>> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
>> [...]
>>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>>> and not the expected IFS=$' \t\n'. All the other
On 6/20/17 1:33 AM, Eduardo A. Bustamante López wrote:
> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
> [...]
>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>> and not the expected IFS=$' \t\n'. All the other unquoted mass
>> This is a regression that ap
On 6/19/17 8:13 PM, Kevin Brodsky wrote:
> Hi,
>
> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
> and not the expected IFS=$' \t\n'. All the other unquoted mass
> expansions ($@, array[*], array[@]) are word-split as if IFS=$'
> \t\n'.
Thanks for the report. This will be
On 20/06/2017 06:33, Eduardo A. Bustamante López wrote:
> On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
> [...]
>> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
>> and not the expected IFS=$' \t\n'. All the other unquoted mass
>> This is a regression that a
On Tue, Jun 20, 2017 at 01:13:07AM +0100, Kevin Brodsky wrote:
[...]
> When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
> and not the expected IFS=$' \t\n'. All the other unquoted mass
> This is a regression that appeared in 4.3 and is still present on devel
[...]
AFAICT, the
Hi,
When IFS is unset, unquoted $* undergoes word splitting as if IFS=' ',
and not the expected IFS=$' \t\n'. All the other unquoted mass
expansions ($@, array[*], array[@]) are word-split as if IFS=$'
\t\n'.For instance:
nb_args() { echo $#; }
set -- $'a\nb'
unset IFS
# Expected: 2,
19 matches
Mail list logo