Re: [coreutils] Re: Builds of coreutils-8.6.19-1369f
From:
Jim Meyering
Subject:
Re: [coreutils] Re: Builds of coreutils-8.6.19-1369f
Date:
Sat, 06 Nov 2010 17:39:15 +0100
Andreas Schwab wrote:
> Jim Meyering <address@hidden> writes:
>
>> IMHO, the fact that VAR=$OTHER_VAL never needs quotes
>> should imply that `local VAR=$OTHER_VAL' also requires no quotes.
>
> I wonder where POSIX requires or even allows that export VAR=$foo does
> not perform word splitting (although the second export example would be
> unsafe with word splitting).
The export built-in of FreeBSD 8.1's /bin/sh does not work as I would
expect (but I haven't read the spec recently):
freebsd$ /bin/sh -c 'v="a b"; export s=$v; echo $s'
a
I was surprised to see that dash-0.5.6-2.fc14.x86_64 agrees:
dash -c 'v="a b"; export s=$v; echo $s'
a
I expected what bash and zsh print:
a b
This makes me think perhaps I should not exclude FreeBSD's /bin/sh.