[Top][All Lists]

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

Re: Failglob issues

From: Chris Down
Subject: Re: Failglob issues
Date: Sun, 1 Sep 2013 16:52:56 +0200
User-agent: Mutt/1.5.21 (2010-09-15)

On 2013-09-01 12:45, Nikolai Kondrashov wrote:
> 1) With both nullglob and failglob enabled it is considered an error for a
>    glob not to match anything. I'd say it's more natural to not produce an
>    error in this case. Otherwise a fairly useful behavior is broken, like
>    glob use in "for" loop:

Well... nullglob *and* failglob are pretty much at odds with each other. I'm
not sure what you expect to happen.

>    Are globs supposed to have an effect in associative array initializers? If
>    yes, what effect, and should this be documented? If not, is it possible
>    that this is a bug and the above shouldn't fail?

This seems a bit more odd to me.

    $ > foo
    $ declare -A foo=([bar]=*)
    $ echo "${foo[bar]}"
    $ shopt -s nullglob
    $ declare -A foo=([bar]=*)
    $ echo "${foo[bar]}"

    $ echo "$BASH_VERSION"

That looks like a bug, maybe.

Attachment: pgpJiWIkRQZEj.pgp
Description: PGP signature

reply via email to

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