On 3/19/24 8:56 PM, Zachary Santer wrote:
So I can get a couple of the things I want by manipulating what I get out of ${var@A} with fairly straightforward parameter expansions. If I needed a declare command and wasn't sure if I would get one, I haven't found a way to expand that to something that is guaranteed to be a declare command maintaining attribute settings. I think you're stuck using an if block at that point.
That expansion will produce a declare command if the variable has any attributes, since it needs one to reproduce them. If the variable has a value, but no attributes, you'll get an assignment statement. If there are no attributes and no value, you get nothing. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRU c...@case.edu http://tiswww.cwru.edu/~chet/