On 1/19/26 10:18 PM, Matt Whitlock wrote:
> On Sunday, 18 January 2026 03:59:56 EST, James Le Cuirot wrote:
>> +meson_add_machine_file() {
>> + local file=${T}/meson.${CHOST}.${ABI}.${1}.ini
>
> Also, you should at least change that ${1} to ${1:?} so that you raise an
> error if the function argument is missing or blank.
:? is not a proper error reporting mechanism, use
[[ -n ${xxx} ]] || die "explanatory message"
${xxx:?} is the same class of error as calling abort() in C and saying
"look, it exited nonzero, that's totally safe and clean" meanwhile it is
explicitly documented to not run atexit handlers or perform any form of
cleanup.
--
Eli Schwartz
OpenPGP_signature.asc
Description: OpenPGP digital signature
