diff options
author | Fariborz Jahanian <fjahanian@apple.com> | 2011-02-11 18:46:17 +0000 |
---|---|---|
committer | Fariborz Jahanian <fjahanian@apple.com> | 2011-02-11 18:46:17 +0000 |
commit | d263fd1451299b1e5f5f1acb2bb13b0a4119aee8 (patch) | |
tree | e285db71f901af2f1c0b4a5dd04ef4d38c987569 /test/Sema/block-return.c | |
parent | 9b555ea217565ac0f8bf7255b29496916cb03476 (diff) |
Fix a block sema bug where result type of initializer
is unqualified but its initialized is qualified.
This is for c only and fixes the imm. problem.
c++ is more involved and is wip.
// rdar://8979379
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@125386 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/Sema/block-return.c')
-rw-r--r-- | test/Sema/block-return.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/test/Sema/block-return.c b/test/Sema/block-return.c index 23dbbc2ce6..c6e1e9dc54 100644 --- a/test/Sema/block-return.c +++ b/test/Sema/block-return.c @@ -110,7 +110,7 @@ void foo6() { void foo7() { - const int (^BB) (void) = ^{ const int i = 1; return i; }; // expected-error{{incompatible block pointer types initializing 'const int (^)(void)' with an expression of type 'int (^)(void)'}} + const int (^BB) (void) = ^{ const int i = 1; return i; }; // OK - initializing 'const int (^)(void)' with an expression of type 'int (^)(void)' const int (^CC) (void) = ^const int{ const int i = 1; return i; }; |