bug-bash
[Top][All Lists]
Advanced

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

Re: buddy for ${parameter:?word} needed?


From: Paul Jarc
Subject: Re: buddy for ${parameter:?word} needed?
Date: Thu, 20 Dec 2001 23:56:38 -0500
User-agent: Gnus/5.090004 (Oort Gnus v0.04) Emacs/20.7 (i386-redhat-linux-gnu)

Dan Jacobson <jidanni@deadspam.com> wrote:
> Should
>        ${parameter:?word}
>               Display Error if Null or Unset.
> have a buddy feature added to
>               Display Error if Null or set.

Null implies set.
unset foo # foo is unset
foo=''    # foo is set (and null)
foo=x     # foo is set (and non-null)

> or would this be used so few that it wouldn't be worth, and the user
> could just do the test "x$bla" != x if needed anyway.

That's a different test.  "test ${bla+x} != x" checks whether the
variable is set.


paul



reply via email to

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