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

Subversion Repositories openrisc

[/] [openrisc/] [trunk/] [gnu-dev/] [or1k-gcc/] [gcc/] [testsuite/] [objc.dg/] [attributes/] [objc-exception-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>, February 2011.  */
2
/* { dg-do compile } */
3
 
4
/* Test that the 'objc_exception' attribute is accepted for
5
   @interfaces, but not for anything else.  */
6
 
7
#include <objc/objc.h>
8
 
9
/* Fine.  */
10
__attribute__ ((objc_exception))
11
@interface MyClass
12
{
13
  Class isa;
14
}
15
@end
16
 
17
/* Fine.  */
18
__attribute__ ((__objc_exception__))
19
@interface MyClass2
20
{
21
  Class isa;
22
}
23
@end
24
 
25
__attribute__ ((objc_exception))
26
@protocol MyProtocol; /* { dg-warning "ignored" } */
27
 
28
__attribute__ ((objc_exception))
29
int myVariable; /* { dg-warning "ignored" } */
30
 
31
__attribute__ ((objc_exception))
32
int myFunction (int argument); /* { dg-warning "ignored" } */

powered by: WebSVN 2.1.0

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