1 /* Check if method parameters that are functions are gracefully decayed
3 /* Contributed by Ziemowit Laski <zlaski@apple.com> */
5 /* { dg-xfail-run-if "Needs OBJC2 ABI" { *-*-darwin* && { lp64 && { ! objc2 } } } { "-fnext-runtime" } { "" } } */
8 /* provide an Object class for NeXT runtimes 10.5 and above */
9 #include "../objc-obj-c++-shared/Object1.h"
11 @interface Func: Object
12 + (int) processNumber:(int)a and:(int)b usingFunction:(int(int,int))func;
16 + (int) processNumber:(int)a and:(int)b usingFunction:(int(int,int))func {
21 static int my_computation(int a, int b) {
25 static int processNumber(int a, int b, int func(int, int)) {
30 int result = processNumber (6, 8, my_computation);
34 result = [Func processNumber:8 and:6 usingFunction:my_computation];
41 #include "../objc-obj-c++-shared/Object1-implementation.h"