Re: documentation for ${@: -1} is unclear

2022-12-21 Thread Chet Ramey
On 12/20/22 3:40 PM, Emanuele Torre wrote: The bash manual says: Thanks for the report. -- ``The lyf so short, the craft so long to lerne.'' - Chaucer ``Ars longa, vita brevis'' - Hippocrates Chet Ramey, UTech, CWRUc...@case.eduhttp://tiswww.cwru.edu/~chet/

documentation for ${@: -1} is unclear

2022-12-20 Thread Emanuele Torre
The bash manual says: If parameter is ‘@’ or ‘*’, the result is length positional parameters beginning at offset. A negative offset is taken relative to one greater than the greatest positional parameter, so an offset of -1 evaluates to the last positional parameter. It is an expansion error