On 2/21/08, Travis Vitek <[EMAIL PROTECTED]> wrote:
>
>
>  >Mark Brown wrote:
>  >
>  >On 2/19/08, Martin Sebor <[EMAIL PROTECTED]> wrote:
>  >>Travis Vitek wrote:
>  >>> sebor-2 wrote:
>  >>>> +    // weirdly-formed brace expansions -- fixed in post-bash-3.1
>  >>>> +    TEST ("a-{b{d,e}}-c",    "a-{bd}-c a-{be}-c");
>  >>>>
>  >>>
>  >>> I don't understand how this could be interpreted as valid
>  >>> brace expansion at all. The body of the expansion is '{b{d,e}}'.
>  >>> Paragraph 5 [and paragraph 1 for that matter] require a
>  >>> correctly-formed brace expansion have unquoted [unescaped?]
>  >>> opening and closing braces, and at least one unquoted comma or
>  >>> a valid sequence expression. The body does not meet either of
>  >>> these requirements, so it must be invalid.
>  >>>
>  >
>  >The C-Shell that had brace expansion long before Bash did outputs
>  >a-bd-c a-be-c as Martin expects. It doesn't require a comma at all.
>
>
> Yes, but "a-bd-c a-be-c" is very different from "a-{bd}-c a-{be}-c",
>  which the test expects.

Mea culpa! My eyesight must be going. I completely overlooked the braces.

>
>  Many of the shells implement brace expansion in one way or another. One
>  problem that I see with bash is that the documentation appears to be out
>  of date or incomplete. The man pages [and the reference manual]
>  explicitly say...
>
>     A correctly-formed brace expansion must contain unquoted opening
>
>     and closing braces, and at least one unquoted comma or a valid
>
>     sequence expression. Any incorrectly formed brace expansion is
>     left unchanged.

According to the Bash FAQ this is supposed to be the only difference.
http://www.unixguide.net/unix/bash/D2.shtml

-- Mark

Reply via email to