diff options
author | Gaius Mulley <gaiusmod2@gmail.com> | 2023-03-16 20:41:20 +0000 |
---|---|---|
committer | Gaius Mulley <gaiusmod2@gmail.com> | 2023-03-16 20:41:20 +0000 |
commit | f231bca93ca92f6fd55de6fbe4bf8935f9ec558a (patch) | |
tree | 93cd0e97bb5694d8362623bbefe43a43748d67b2 /gcc | |
parent | 77924dff144cf934e7a73417d237a99f0d9d66ed (diff) | |
download | gcc-f231bca93ca92f6fd55de6fbe4bf8935f9ec558a.zip gcc-f231bca93ca92f6fd55de6fbe4bf8935f9ec558a.tar.gz gcc-f231bca93ca92f6fd55de6fbe4bf8935f9ec558a.tar.bz2 |
PR modula2/109125 SIGBUS in m2pim_ldtoa_ldtoa
13 regression failures seen on sparc SIGBUS in m2pim_ldtoa_ldtoa.
This patch fixes int bool struct field mismatches between the
definition modules and their C/C++ implementations.
gcc/testsuite/ChangeLog:
PR modula2/109125
* gm2/types/run/pass/d.c: Convert data structure from
BOOLEAN int to bool and cast int to bool in test function.
Signed-off-by: Gaius Mulley <gaiusmod2@gmail.com>
Diffstat (limited to 'gcc')
-rw-r--r-- | gcc/testsuite/gm2/types/run/pass/d.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/gcc/testsuite/gm2/types/run/pass/d.c b/gcc/testsuite/gm2/types/run/pass/d.c index 17b9125..31d497d 100644 --- a/gcc/testsuite/gm2/types/run/pass/d.c +++ b/gcc/testsuite/gm2/types/run/pass/d.c @@ -22,7 +22,7 @@ typedef struct { union { struct { int foo; - int bar; + bool bar; union { int bt; int bf; @@ -45,11 +45,10 @@ void d_test (this *s, int n, int v) case 1: assert(s->tag == v); break; case 2: assert(s->that.first.foo == v); break; - case 3: assert(s->that.first.bar == v); break; + case 3: assert(s->that.first.bar == (bool) v); break; case 4: assert(s->that.first.inner.bt == v); break; case 5: assert(s->that.first.inner.bf == v); break; case 6: assert(s->that.an == v); break; case 7: assert(s->final == v); break; } } - |