OpenCores
URL https://opencores.org/ocsvn/openrisc/openrisc/trunk

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [objc.dg/] [protocol-forward-1.m] - Blame information for rev 801

Go to most recent revision | Details | Compare with Previous | View Log

Line No. Rev Author Line
1 704 jeremybenn
/* Contributed by Nicola Pero <nicola.pero@meta-innovation.com>, December 2010.  */
2
/* { dg-do compile } */
3
 
4
/* Test that all protocols appearing in @interface declarations are
5
   real (ie, we saw a full @protocol definition with list of methods),
6
   and not just forward-references (ie, "@protocol NSObject;").  */
7
 
8
#include <objc/objc.h>
9
 
10
@protocol MyProtocol;
11
 
12
@protocol MyProtocol2
13
- (int)method2;
14
@end
15
 
16
@interface MyClass <MyProtocol> /* { dg-warning "definition of protocol .MyProtocol. not found" } */
17
@end
18
 
19
@interface MyClass2 <MyProtocol2> /* Ok */
20
@end
21
 
22
@interface MyClass2 (Category) <MyProtocol>  /* { dg-warning "definition of protocol .MyProtocol. not found" } */
23
@end
24
 
25
@protocol MyProtocol3 <MyProtocol> /* Ok */
26
@end

powered by: WebSVN 2.1.0

© copyright 1999-2024 OpenCores.org, equivalent to Oliscience, all rights reserved. OpenCores®, registered trademark.