On Mon, Nov 21, 2022, at 4:38 AM, Ulrich Windl wrote: > But from the syntax "${parameter:-word}" it's not really obvious that the > colon may be omitted.
You're not wrong. > Should it be "${parameter[:]-word}" (with non-bold square brackets) instead > (as for "name=[value]")? No, that would be extremely confusing. But I think something like this has been suggested before (I don't remember by whom): ${parameter-word} ${parameter:-word} Use Default Values. [...] ${parameter=word} ${parameter:=word} Assign Default Values. [...] ${parameter?word} ${parameter:?word} Display Error if Null or Unset. [...] ${parameter+word} ${parameter:+word} Use Alternate Value. [...] > Despite of that only ":-" is typeset in bold; shouldn't "${" and "}" be > typeset in bold, too? I don't know. It seems like boldface is used to highlight the parts that are unique to each form. -- vq