summaryrefslogtreecommitdiffstats
path: root/clang/test/Analysis/array-struct.c
diff options
context:
space:
mode:
authorZhongxing Xu <xuzhongxing@gmail.com>2009-05-03 00:27:40 +0000
committerZhongxing Xu <xuzhongxing@gmail.com>2009-05-03 00:27:40 +0000
commit3e3e69bbe72308336ac955b1e21cb9d121496ac3 (patch)
treec900060106a6e92279759e0c8c537f146c9903bc /clang/test/Analysis/array-struct.c
parentb7126db9b02f5bc8ececbd2daf164a1eb43a86ee (diff)
downloadbcm5719-llvm-3e3e69bbe72308336ac955b1e21cb9d121496ac3.tar.gz
bcm5719-llvm-3e3e69bbe72308336ac955b1e21cb9d121496ac3.zip
region store: make Retrieve() can retrieve embedded array correctly. Also
simplify the retrieve logic. llvm-svn: 70651
Diffstat (limited to 'clang/test/Analysis/array-struct.c')
-rw-r--r--clang/test/Analysis/array-struct.c11
1 files changed, 11 insertions, 0 deletions
diff --git a/clang/test/Analysis/array-struct.c b/clang/test/Analysis/array-struct.c
index 7e5e6243c6a..0ce6afcc0c0 100644
--- a/clang/test/Analysis/array-struct.c
+++ b/clang/test/Analysis/array-struct.c
@@ -119,3 +119,14 @@ void f13(double timeout) {
if (a.e.d == 10)
a.e.d = 4;
}
+
+struct s3 {
+ int a[2];
+};
+
+static struct s3 opt;
+
+// Test if the embedded array is retrieved correctly.
+void f14() {
+ struct s3 my_opt = opt;
+}
OpenPOWER on IntegriCloud