Path: csiph.com!goblin2!goblin1!goblin.stu.neva.ru!usenet.stanford.edu!not-for-mail From: Greg Wooledge Newsgroups: gnu.bash.bug Subject: Re: Unquoted array slice ${a[@]:0} expands to just one word if IFS doesn't have a space Date: Wed, 1 Aug 2018 09:40:12 -0400 Lines: 17 Approved: bug-bash@gnu.org Message-ID: References: <20180801121251.efyquoibrsneiqbl@eeg.ccf.org> NNTP-Posting-Host: lists.gnu.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: usenet.stanford.edu 1533130823 3794 208.118.235.17 (1 Aug 2018 13:40:23 GMT) X-Complaints-To: action@cs.stanford.edu To: bug-bash@gnu.org Envelope-to: bug-bash@gnu.org Mail-Followup-To: bug-bash@gnu.org Content-Disposition: inline In-Reply-To: User-Agent: NeoMutt/20170113 (1.7.2) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] [fuzzy] X-Received-From: 139.137.100.1 X-BeenThere: bug-bash@gnu.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: Bug reports for the GNU Bourne Again SHell List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Xref: csiph.com gnu.bash.bug:14432 On Wed, Aug 01, 2018 at 04:06:03PM +0300, Ilkka Virta wrote: > Unquoted $* seems well-defined in Bash's reference manual: > > ($*) Expands to the positional parameters, starting from one. When the > expansion is not within double quotes, each positional parameter > expands to a separate word. But not in reality. https://lists.gnu.org/archive/html/bug-bash/2017-06/msg00283.html https://lists.gnu.org/archive/html/bug-bash/2017-09/msg00058.html https://lists.gnu.org/archive/html/bug-bash/2018-01/msg00035.html Unquoted $* or $@ is just a disaster. Don't do it.