public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
* [PATCH] [testsuite] [arm] accept empty init for bfloat16
@ 2024-04-16  3:50 Alexandre Oliva
  2024-04-16  8:59 ` Richard Earnshaw (lists)
  2024-04-16 22:42 ` Mike Stump
  0 siblings, 2 replies; 4+ messages in thread
From: Alexandre Oliva @ 2024-04-16  3:50 UTC (permalink / raw)
  To: gcc-patches
  Cc: Rainer Orth, Mike Stump, Nick Clifton, Richard Earnshaw,
	Ramana Radhakrishnan


Complete r13-2205, adjusting an arm-specific test that expects a
no-longer-issued error at an empty initializer.

Regstrapped on x86_64-linux-gnu.  Also tested with gcc-13 on arm-,
aarch64-, x86- and x86_64-vxworks7r2.  Ok to install?


for  gcc/testsuite/ChangeLog

	* gcc.target/arm/bfloat16_scalar_typecheck.c: Accept C23
        empty initializers.
---
 .../gcc.target/arm/bfloat16_scalar_typecheck.c     |    4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/gcc/testsuite/gcc.target/arm/bfloat16_scalar_typecheck.c b/gcc/testsuite/gcc.target/arm/bfloat16_scalar_typecheck.c
index 8c80c55bc9f4c..04ede93bda152 100644
--- a/gcc/testsuite/gcc.target/arm/bfloat16_scalar_typecheck.c
+++ b/gcc/testsuite/gcc.target/arm/bfloat16_scalar_typecheck.c
@@ -42,7 +42,7 @@ bfloat16_t footest (bfloat16_t scalar0)
   short initi_1_4 = glob_bfloat; /* { dg-error {invalid conversion from type 'bfloat16_t'} } */
   double initi_1_5 = glob_bfloat; /* { dg-error {invalid conversion from type 'bfloat16_t'} } */
 
-  bfloat16_t scalar2_1 = {}; /* { dg-error {empty scalar initializer} } */
+  bfloat16_t scalar2_1 = {};
   bfloat16_t scalar2_2 = { glob_bfloat };
   bfloat16_t scalar2_3 = { 0 }; /* { dg-error {invalid conversion to type 'bfloat16_t'} } */
   bfloat16_t scalar2_4 = { 0.1 }; /* { dg-error {invalid conversion to type 'bfloat16_t'} } */
@@ -94,7 +94,7 @@ bfloat16_t footest (bfloat16_t scalar0)
 
   /* Compound literals.  */
 
-  (bfloat16_t) {}; /* { dg-error {empty scalar initializer} } */
+  (bfloat16_t) {};
   (bfloat16_t) { glob_bfloat };
   (bfloat16_t) { 0 }; /* { dg-error {invalid conversion to type 'bfloat16_t'} } */
   (bfloat16_t) { 0.1 }; /* { dg-error {invalid conversion to type 'bfloat16_t'} } */

-- 
Alexandre Oliva, happy hacker            https://FSFLA.org/blogs/lxo/
   Free Software Activist                   GNU Toolchain Engineer
More tolerance and less prejudice are key for inclusion and diversity
Excluding neuro-others for not behaving ""normal"" is *not* inclusive

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2024-04-18 10:56 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-04-16  3:50 [PATCH] [testsuite] [arm] accept empty init for bfloat16 Alexandre Oliva
2024-04-16  8:59 ` Richard Earnshaw (lists)
2024-04-16 22:42 ` Mike Stump
2024-04-18 10:56   ` Alexandre Oliva

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).