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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [obj-c++.dg/] [comp-types-11.mm] - Blame information for rev 703

Details | Compare with Previous | View Log

Line No. Rev Author Line
1 703 jeremybenn
/* { dg-do compile } */
2
 
3
#include "../objc-obj-c++-shared/TestsuiteObject.h"
4
 
5
@protocol Foo
6
- (id)meth1;
7
- (id)meth2:(int)arg;
8
@end
9
 
10
@interface Derived1: TestsuiteObject
11
@end
12
 
13
@interface Derived2: TestsuiteObject
14
+ (Derived1 *)new;
15
@end
16
 
17
id func(void) {
18
  TestsuiteObject *o = [TestsuiteObject new];
19
  return o;  /* { dg-warning "class .TestsuiteObject. does not implement the .Foo. protocol" } */
20
}
21
 
22
@implementation Derived2
23
+ (Derived1 *)new {
24
  Derived2 *o = [super new];
25
  return o;  /* { dg-warning "distinct Objective\\-C type in return" } */
26
}
27
@end

powered by: WebSVN 2.1.0

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