diff options
author | Chris Lattner <sabre@nondot.org> | 2009-04-21 05:19:11 +0000 |
---|---|---|
committer | Chris Lattner <sabre@nondot.org> | 2009-04-21 05:19:11 +0000 |
commit | 81045d8dcd967def69d8e0945566214a9fe9ffcc (patch) | |
tree | 8fc73049eac5cdf259097d18db04b3d559a3134d /test/Sema/const-eval.c | |
parent | ce84c16a9560b424d109e74126e45f99c6a08fcd (diff) | |
download | clang-81045d8dcd967def69d8e0945566214a9fe9ffcc.tar.gz |
Fix PR4027 + rdar://6808859, we were rejecting implicit casts of
aggregates even though we already accept explicit ones. Easy fix.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@69661 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Sema/const-eval.c')
-rw-r--r-- | test/Sema/const-eval.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/test/Sema/const-eval.c b/test/Sema/const-eval.c index dd91c48236..08daa5f8d6 100644 --- a/test/Sema/const-eval.c +++ b/test/Sema/const-eval.c @@ -55,3 +55,9 @@ EVAL_EXPR(26, (_Complex double)0 ? -1 : 1) EVAL_EXPR(27, (_Complex int)0 ? -1 : 1) EVAL_EXPR(28, (_Complex double)1 ? 1 : -1) EVAL_EXPR(29, (_Complex int)1 ? 1 : -1) + + +// PR4027 + rdar://6808859 +struct a { int x, y }; +static struct a V2 = (struct a)(struct a){ 1, 2}; +static const struct a V1 = (struct a){ 1, 2}; |