Fix unused warnings.
[official-gcc/graphite-test-results.git] / gcc / testsuite / objc / execute / protocol-isEqual-4.m
blob4d5af640e46b9abc5b55f22d4f9969ebfd599597
1 /* Contributed by David Ayers - Fri Jun  4 03:16:17 BST 2004 */
2 /* Test that a protocol is not equal to something which is not a protocol.  */
4 #include "../../objc-obj-c++-shared/Protocol1.h"
6 @protocol Foo
7 - (void)foo;
8 @end
10 int main (void)
12   /* A Protocol object should not be equal to a Class object.  */
13 #ifdef NEXT_OBJC_USE_NEW_INTERFACE
14   if (protocol_isEqual (@protocol(Foo), objc_getClass("Protocol")))
15 #else
16   if ([@protocol(Foo) isEqual: [Protocol class]])
17 #endif
18     {
19       abort ();
20     }
21   
22   return 0;