[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Why does case-pattern undergo "process substitution"?
From: |
Eric Pruitt |
Subject: |
Re: Why does case-pattern undergo "process substitution"? |
Date: |
Sat, 24 Aug 2024 17:01:20 -0700 |
On Sat, Aug 24, 2024 at 08:27:38AM +0000, shynur . wrote:
> > the behavior is easily confirmed.
> >
> > $ case <(:) in '<(:)') echo not expanded;; *) echo expanded;; esac
> > expanded
>
> Indeed, despite the manual doesn't mention "process substitution":
>
> The _word_ undergoes tilde expansion, parameter expansion,
> command substitution, arithmetic expansion, and quote
> removal before matching is attempted.
You're quoting an old version of the man page. Documentation for Bash
5.2 reads:
case word in [ [(] pattern [ | pattern ] ... ) list ;; ] ... esac
[...] The word is expanded using tilde expansion, parameter and
variable expansion, arithmetic expansion, command substitution,
>>>process substitution<<< and [...]
That matches what Lawrence posted.
Eric
- Why does case-pattern undergo "process substitution"?, shynur ., 2024/08/23
- Re: Why does case-pattern undergo "process substitution"?, Eric Pruitt, 2024/08/23
- Re: Why does case-pattern undergo "process substitution"?, shynur ., 2024/08/23
- Re: Why does case-pattern undergo "process substitution"?, Lawrence Velázquez, 2024/08/23
- Re: Why does case-pattern undergo "process substitution"?, shynur ., 2024/08/24
- Re: Why does case-pattern undergo "process substitution"?,
Eric Pruitt <=
- Re: Why does case-pattern undergo "process substitution"?, Lawrence Velázquez, 2024/08/24
- Re: Why does case-pattern undergo "process substitution"?, Eric Pruitt, 2024/08/24
- Re: Why does case-pattern undergo "process substitution"?, Chet Ramey, 2024/08/26
- Re: Why does case-pattern undergo "process substitution"?, Chet Ramey, 2024/08/26