Improving the usefulness of `#[must_use]`

For some similar tests in the past I’ve preferred assert!(the_result.is_err()). (Clippy briefly wanted this to be changed to assert-matches, but I think the bool version is more readable).

Personally, I would wrap it in a macro which checks that the function call really returned 0, and panics otherwise. Bugs happen, FFI functions sometimes behave unexpectedly, and an extra check is much cheaper than hunting for an obscure bug.