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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [objc.dg/] [enhanced-proto-2.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
/* Test use of @optional/@required keywords in @protocol class. */
2
/* { dg-do compile } */
3
 
4
@protocol MyProto1
5
@optional
6
- (void) FOO;
7
@optional
8
- (void) FOO;
9
@optional
10
- (void) REQ;
11
@optional
12
@end
13
 
14
@interface  MyProto2 <MyProto1>
15
@required               /* { dg-error ".@required. is allowed in @protocol context only" }  */
16
- (void) FOO2;
17
@optional               /* { dg-error ".@optional. is allowed in @protocol context only" }  */
18
- (void) FOO3;
19
@end
20
 
21
@implementation MyProto2
22
- (void) FOO2{}
23
- (void) FOO3{}
24
@end

powered by: WebSVN 2.1.0

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