File: ivar-sem-check-1.m

package info (click to toggle)
llvm-toolchain-15 1%3A15.0.6-4
  • links: PTS, VCS
  • area: main
  • in suites: bookworm
  • size: 1,554,644 kB
  • sloc: cpp: 5,922,452; ansic: 1,012,136; asm: 674,362; python: 191,568; objc: 73,855; f90: 42,327; lisp: 31,913; pascal: 11,973; javascript: 10,144; sh: 9,421; perl: 7,447; ml: 5,527; awk: 3,523; makefile: 2,520; xml: 885; cs: 573; fortran: 567
file content (20 lines) | stat: -rw-r--r-- 774 bytes parent folder | download | duplicates (13)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
// RUN: %clang_cc1 -fsyntax-only -verify %s

struct S; // expected-note{{forward declaration of 'struct S'}}
typedef int FOO(void);

@interface INTF
{
	struct F {} JJ;
	int arr[];  // expected-error {{flexible array member 'arr' with type 'int[]' is not at the end of class}}
	struct S IC;  // expected-error {{field has incomplete type}}
	              // expected-note@-1 {{next instance variable declaration is here}}
	struct T { // expected-note {{previous definition is here}}
	  struct T {} X;  // expected-error {{nested redefinition of 'T'}}
	}YYY; 
	FOO    BADFUNC;  // expected-error {{field 'BADFUNC' declared as a function}}
	int kaka;	// expected-note {{previous declaration is here}}
	int kaka;	// expected-error {{duplicate member 'kaka'}}
	char ch[];
}
@end