]> git.ipfire.org Git - thirdparty/gcc.git/commitdiff
aarch64: Define out-of-class static constants
authorRichard Sandiford <richard.sandiford@arm.com>
Wed, 6 Mar 2024 10:04:56 +0000 (10:04 +0000)
committerRichard Sandiford <richard.sandiford@arm.com>
Wed, 6 Mar 2024 10:04:56 +0000 (10:04 +0000)
While reworking the aarch64 feature descriptions, I forgot
to add out-of-class definitions of some static constants.
This could lead to a build failure with some compilers.

This was seen with some WIP to increase the number of extensions
beyond 64.  It's latent on trunk though, and a regression from
before the rework.

gcc/
* config/aarch64/aarch64-feature-deps.h (feature_deps::info): Add
out-of-class definitions of static constants.

gcc/config/aarch64/aarch64-feature-deps.h

index a1b81f9070bfd9a5f313e99ab210edcc11da6a3e..3641badb82f5d14c6a53e05552f41f75eed3aaa2 100644 (file)
@@ -71,6 +71,9 @@ template<aarch64_feature> struct info;
     static constexpr auto enable = flag | get_enable REQUIRES;         \
     static constexpr auto explicit_on = enable | get_enable EXPLICIT_ON; \
   };                                                                   \
+  const aarch64_feature_flags info<aarch64_feature::IDENT>::flag;      \
+  const aarch64_feature_flags info<aarch64_feature::IDENT>::enable;    \
+  const aarch64_feature_flags info<aarch64_feature::IDENT>::explicit_on; \
   constexpr info<aarch64_feature::IDENT> IDENT ()                      \
   {                                                                    \
     return info<aarch64_feature::IDENT> ();                            \