summaryrefslogtreecommitdiff
path: root/gcc/testsuite
diff options
context:
space:
mode:
authorErick Ochoa <erick.ochoa@theobroma-systems.com>2020-02-11 20:57:39 +0100
committerErick Ochoa <erick.ochoa@theobroma-systems.com>2020-06-03 16:05:05 +0200
commit802839165ed6c342f0b591575079a7decb176e55 (patch)
tree28aabcd1086f0d335ee9fdeb9f923fb307d4ac24 /gcc/testsuite
parent583c7bb54f0fada0847f9c04e1672328d000d613 (diff)
passes function pointer test
Diffstat (limited to 'gcc/testsuite')
-rw-r--r--gcc/testsuite/gcc.dg/ipa/ipa-structreorg-48-function-ptr-0.c13
1 files changed, 7 insertions, 6 deletions
diff --git a/gcc/testsuite/gcc.dg/ipa/ipa-structreorg-48-function-ptr-0.c b/gcc/testsuite/gcc.dg/ipa/ipa-structreorg-48-function-ptr-0.c
index f1c06f3ca4a..063d8f76a32 100644
--- a/gcc/testsuite/gcc.dg/ipa/ipa-structreorg-48-function-ptr-0.c
+++ b/gcc/testsuite/gcc.dg/ipa/ipa-structreorg-48-function-ptr-0.c
@@ -21,10 +21,11 @@ _Bool returnLast2(struct arc anArc)
int
main(int argc, char** argv) {
- (_Bool )(*func1)(struct arc) = returnLast;
- (_Bool )(*func2)(struct arc) = returnLast2;
- struct arc anArc;
- anArc.c = argc;
- assert(func1(anArc) == func2(anArc));
+_Bool(*func1)(struct arc);
+func1 = &returnLast;
+_Bool (*func2)(struct arc);
+func2 = &returnLast2;
+struct arc anArc;
+anArc.c = argc;
+assert(func1(anArc) == func2(anArc));
}
-