bug-bash
[Top][All Lists]
Advanced

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

Re: problem anomalies , possibly aliases related


From: Martin D Kealey
Subject: Re: problem anomalies , possibly aliases related
Date: Thu, 20 Jul 2023 23:03:35 +1000

On Thu, 20 Jul 2023, 18:03 Grisha Levit, <grishalevit@gmail.com> wrote:

> Sounds like you want all the commands in the alias to be executed as a
> group -- so you can just write it as one:
>
> alias bad='{ echo fail; continue; }'
>

That right there USED to work as a function:

 bad() { echo fail; continue; }

But then someone suggested allowing non-local break & continue was a bug,
and the few people who considered it couldn't think of even as simple an
example as that right there.

So it was "fixed", and now that function doesn't work. It sickens me that
the work-around is to enable alias expansion in scripts.

*Grumble*
-Martin

PS: and people think I'm crazy for wanting to write new stuff in Perl, in
preference to Bash. Bash as a language has nothing else going for it, so if
after 28 years I still can't consider it stable, what is the point?

>


reply via email to

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