>Is this enough of a special case to make it different?

Well, to me the @A and @a expansion operators always looked different from all 
the others as they expand to the *attributes* of the variable rather than to a 
function of the variable's *value*. They almost seemed like faster versions of 
declare -p. Namerefs are transparent for get-value/set-value type operations. 
Should they be transparent for attribute-focused expansions as well? Namerefs 
do have unique attributes of their own that the code may want to efficiently 
examine.


On Friday, October 17, 2025 at 12:49:10 PM PDT, Chet Ramey 
<[email protected]> wrote: 


Interesting question. In every other word expansion, referencing a nameref
variable performs the resolution and uses the variable the nameref resolves
to. The only places you can get to the nameref directly are `declare' and
`unset'. Is this enough of a special case to make it different?

-- 
``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/


Reply via email to