sh.lang: Fix parameter detection in parameter expansion
In case of array parameter expansion, a second parameter can match which should not : in {arr[@]/a/b}
, a
matches, or in {arr[@]##txt}
, the first #
matches (as special parameter).
This MR fixes this issue.
Edited by Gaël Bonithon