summaryrefslogtreecommitdiffstats
path: root/clang/test/CodeGen/struct.c
diff options
context:
space:
mode:
Diffstat (limited to 'clang/test/CodeGen/struct.c')
-rw-r--r--clang/test/CodeGen/struct.c18
1 files changed, 18 insertions, 0 deletions
diff --git a/clang/test/CodeGen/struct.c b/clang/test/CodeGen/struct.c
index a3753d314a6..cc6f0aaeeb1 100644
--- a/clang/test/CodeGen/struct.c
+++ b/clang/test/CodeGen/struct.c
@@ -37,3 +37,21 @@ int fn3(F2 *c) {
else
return 0;
}
+
+/* Nested structs */
+typedef struct NA {
+ int data;
+ struct NA *next;
+} NA;
+void f1() { A a; }
+
+typedef struct NB {
+ int d1;
+ struct _B2 {
+ int d2;
+ struct NB *n2;
+ } B2;
+} NB;
+
+void f2() { NB b; }
+
OpenPOWER on IntegriCloud