blob: a84d0b2c6aca5db6729872445d0040f3261b9aa9 [file] [log] [blame]
Daniel Dunbara5728872009-12-15 20:14:24 +00001// RUN: %clang_cc1 -o %t -emit-llvm -g %s
Mike Stump91cc8152009-10-23 01:52:13 +00002// RUN: FileCheck --input-file=%t %s
Daniel Dunbard7f60502008-11-08 04:42:29 +00003
Chris Lattner5c11d4e2008-11-11 06:27:34 +00004// PR3023
Daniel Dunbard7f60502008-11-08 04:42:29 +00005void convert(void) {
6 struct { typeof(0) f0; } v0;
7}
Chris Lattner14132172008-11-11 06:42:53 +00008
Mike Stump91cc8152009-10-23 01:52:13 +00009
Chris Lattner14132172008-11-11 06:42:53 +000010// PR2784
11struct OPAQUE;
12typedef struct OPAQUE *PTR;
13PTR p;
14
15
16// PR2950
17struct s0;
18struct s0 { struct s0 *p; } g0;
19
20struct s0 *f0(struct s0 *a0) {
21 return a0->p;
22}
Nuno Lopes010d5142009-01-28 00:35:17 +000023
Mike Stump91cc8152009-10-23 01:52:13 +000024
Anders Carlsson4d6e8dd2008-11-26 17:40:42 +000025// PR3134
26char xpto[];
27
Mike Stump91cc8152009-10-23 01:52:13 +000028
Nuno Lopes010d5142009-01-28 00:35:17 +000029// PR3427
30struct foo {
Mike Stump1eb44332009-09-09 15:08:12 +000031 int a;
32 void *ptrs[];
Nuno Lopes010d5142009-01-28 00:35:17 +000033};
34struct foo bar;
Eli Friedman3189e4b2009-05-04 04:39:55 +000035
Mike Stump91cc8152009-10-23 01:52:13 +000036
Eli Friedman3189e4b2009-05-04 04:39:55 +000037// PR4143
38struct foo2 {
Mike Stump1eb44332009-09-09 15:08:12 +000039 enum bar *bar;
Eli Friedman3189e4b2009-05-04 04:39:55 +000040};
41
42struct foo2 foo2;
Mike Stump91cc8152009-10-23 01:52:13 +000043
44
Mike Stump386378d2009-10-23 02:13:20 +000045// Radar 7325611
Mike Stump91cc8152009-10-23 01:52:13 +000046// CHECK: "barfoo"
47typedef int barfoo;
48barfoo foo() {
49}