[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Word splitting for $@ in variable assignment
From: |
Nora Platiel |
Subject: |
Re: Word splitting for $@ in variable assignment |
Date: |
Fri, 25 Jun 2021 21:00:35 +0200 |
On 2021-06-25 12:11, Greg Wooledge wrote:
> > | A variable may be assigned to by a statement of the form
> > | name=[value]
> > | [...]
> > | Word splitting is not performed, with the exception of "$@" as
> > | explained below.
>
> This isn't the full sentence in the current man page. In the bash 5.1
> man page, it says:
>
> Word splitting is not
> performed, with the exception of "$@" as explained below under Special
> Parameters.
Ok, so I quoted the web version which is slightly out of date, but the meaning
of "below" was already clear to me. I linked to that part in my previous
message.
I repeat for the 3rd time: the part under Special Parameters is already clear
to me and I see no problem with it.
The part I have a problem with is `with the exception of "$@"'.
Try to follow my reasoning and tell me where our point of divergence is:
(This is all in the context of `name=[value]'.)
- doc: "word splitting is not performed, with the exception of "$@" [...]"
therefore
- in case of "$@" (as an exception), word splitting *is* performed
therefore
- the behavior of var="$@" should be the one described under Special Parameters
when word splitting *is* performed
- but the behavior of var="$@" is actually the one described under Special
Parameters when word splitting is *not* performed
therefore
- even for "$@", word splitting is *not* performed
therefore
- there is no exception: word splitting is *not* performed, period.
> If Chet feels that a change is needed here, I would remove the "with
> the exception of" clause entirely. Just say "Word splitting is not
> performed."
This is what I've been proposing from the start. Because "with the exception
of" makes it logically incorrect.
- Re: Word splitting for $@ in variable assignment, (continued)