compat/getopt: add {} to complex ifs