On 4/6/26 3:01 PM, Koichi Murase wrote:
2026年4月7日(火) 0:01 Chet Ramey <[email protected]>:On 4/2/26 5:23 AM, Koichi Murase wrote:I'm also interested in this. We already have some functions that return an array through REPLY in bash-completion (see e.g. Ref. [1]).This doesn't depend on REPLY specifically and could just as easily use a different variable name.What do you mean?
There is currently no special meaning associated with REPLY within a shell function. The fact that this is using REPLY is not demonstrative of anything besides the fact that it's using REPLY -- it could just as easily use $COMP_DEQUOTE or something else.
I meant that we already have functions assigning results to REPLY as an array, so that the suggested "array substitution" can be readily used with those functions.
Ah, so your intent is that these functions would not have to change. Which is ok, but not really an argument for doing this one way or another.
If a function uses "a different variable name" as you suggest, that function cannotbe used with array substitution, which is not useful.
OK, you don't want the functions to change.
Or do you intend to implement the array substitution to use a different variable name?
I don't have any intentions yet.
--
``The lyf so short, the craft so long to lerne.'' - Chaucer
``Ars longa, vita brevis'' - Hippocrates
Chet Ramey, UTech, CWRU [email protected] http://tiswww.cwru.edu/~chet/
OpenPGP_signature.asc
Description: OpenPGP digital signature
