[Top][All Lists]

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

Re: Syntax Question...

From: Linda Walsh
Subject: Re: Syntax Question...
Date: Thu, 18 Aug 2011 10:13:45 -0700
User-agent: Mozilla/5.0 (Windows; U; Windows NT 6.0; en-US; rv: Gecko/20100228 Thunderbird/ Mnenhy/

` Chet Ramey wrote:
On 8/18/11 9:37 AM, Greg Wooledge wrote:

   The  word  following the redirection operator in the following descrip-
   tions, unless otherwise noted, is subjected to brace  expansion,  tilde
   expansion, parameter expansion, command substitution, arithmetic expan???
   sion, quote removal, pathname expansion, and  word  splitting.
^^^^^^^^^^^^^^^^^^ If it
   expands to more than one word, bash reports an error.

It seems to leave off variable expansion.
I don't understand this... either it should be reporting an error, or
it should *not* be expanding the variable.  It doesn't seem to report
an error on multiple-file pathname expansions either:

imadev:~$ read a <<< *.pdf
imadev:~$ echo "$a"

In fact, it's not even performing the expansion, as far as I can tell.

The quoted paragraph applies to all redirection operators (and parameter
and variable expansion are still identical).  The description of <<<
notes that it does not perform pathname expansion at all.
Um...the description from "<<<", above indicates it is...subject to pathname expansion...If I had matching filesin my dir, it expanded and returned them,
so I'm pretty sure it does PN expansion.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]