[AArch64] Merge stores of D-register values with different modes
[official-gcc.git] / gcc / testsuite / obj-c++.dg / method-17.mm
blob3566a652bc23105a0a7f6f25fae99192d469108d
1 /* When there is only one candidate method available, make sure the
2    compiler uses its argument/return types when constructing the
3    message sends (so that proper C/C++ argument conversions may
4    take place).  */
5 /* { dg-do run } */
6 /* { dg-xfail-run-if "Needs OBJC2 ABI" { *-*-darwin* && { lp64 && { ! objc2 } } } { "-fnext-runtime" } { "" } } */
7 #include "../objc-obj-c++-shared/TestsuiteObject.m"
8 #include <stdlib.h>
10 #define CHECK_IF(expr) if(!(expr)) abort()
12 static double d = 4.5920234e2;
14 @interface Foo : TestsuiteObject
15 -(void) brokenType: (int)x floatingPoint: (double)y;
16 @end
19 @implementation Foo
20 -(void) brokenType: (int)x floatingPoint: (double)y
22         CHECK_IF(x == 459);
23         CHECK_IF(y == d);
25 @end
27 int main(void)
29         Foo *foo=[Foo new];
30         [foo brokenType: (int)d floatingPoint: d];
31         return 0;