[PATCH 10/23] aarch64: Add an assert to inherent_reg_qualifier

Alice Carlotti alice.carlotti@arm.com
Thu May 7 16:11:36 GMT 2026


The default case isn't useful and is currently unreachable, so add an
assert instead.


diff --git a/gas/config/tc-aarch64.c b/gas/config/tc-aarch64.c
index 0ba4493d936e8a6230c0b90df8a46399daf131bc..b3b73daca473f6437fd5dd0a6566fe2c1ee4cba7 100644
--- a/gas/config/tc-aarch64.c
+++ b/gas/config/tc-aarch64.c
@@ -921,10 +921,7 @@ parse_reg (char **ccp)
   return reg;
 }
 
-/* Return the operand qualifier associated with all uses of REG, or
-   AARCH64_OPND_QLF_NIL if none.  AARCH64_OPND_QLF_NIL means either
-   that qualifiers don't apply to REG or that qualifiers are added
-   using suffixes.  */
+/* Return the operand qualifier associated with all uses of REG.  */
 
 static aarch64_opnd_qualifier_t
 inherent_reg_qualifier (const reg_entry *reg)
@@ -949,7 +946,7 @@ inherent_reg_qualifier (const reg_entry *reg)
       return AARCH64_OPND_QLF_S_B + (reg->type - REG_TYPE_FP_B);
 
     default:
-      return AARCH64_OPND_QLF_NIL;
+      gas_assert (0);
     }
 }
 


More information about the Binutils mailing list