aboutsummaryrefslogtreecommitdiff
path: root/test/Sema/block-return.c
diff options
context:
space:
mode:
Diffstat (limited to 'test/Sema/block-return.c')
-rw-r--r--test/Sema/block-return.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/test/Sema/block-return.c b/test/Sema/block-return.c
index 33fd183be0..5a4ec010d3 100644
--- a/test/Sema/block-return.c
+++ b/test/Sema/block-return.c
@@ -109,10 +109,9 @@ void foo6() {
void foo7()
{
- const int (^BB) (void) = ^{ const int i = 1; return i; }; // expected-error{{incompatible block pointer types initializing 'int const (^)(void)' with an expression of type 'int (^)(void)'}} \
- // expected-warning{{type qualifier on return type has no effect}}
+ const int (^BB) (void) = ^{ const int i = 1; return i; }; // expected-error{{incompatible block pointer types initializing 'int const (^)(void)' with an expression of type 'int (^)(void)'}}
- const int (^CC) (void) = ^const int{ const int i = 1; return i; }; // expected-warning{{type qualifier on return type has no effect}}
+ const int (^CC) (void) = ^const int{ const int i = 1; return i; };
int i;