help-bash
[Top][All Lists]
Advanced

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

Do `>& -` and `<& -` also work?


From: Peng Yu
Subject: Do `>& -` and `<& -` also work?
Date: Mon, 10 May 2021 09:12:44 -0500

Hi,

The manual only mentions `>&-` and `<&-`. Do `>& -` and `<& -` also work?

I tried the following and I don't see errors. But I can not be sure
whether `>& -` and `<& -` are exactly the same as `>&-` and `<&-`.

$ exec 42>& -
$ exec 42<& -

Could anybody confirm?

If they both work, is this made by design? Or it is just an artifact
of the parser (as I don't remember people write code like them)?

-- 
Regards,
Peng



reply via email to

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