summaryrefslogtreecommitdiff
path: root/test/SemaObjC/block-return.m
blob: 15c3fb64d7787d837824250d29cdea809210fca2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
// RUN: %clang_cc1 -triple x86_64-apple-darwin10 -fsyntax-only -verify -fblocks -fobjc-gc-only %s
// rdar://8979379

@interface NSString
- (__attribute__((objc_gc(strong))) const char *)UTF8String;
@end

int main() {
__attribute__((objc_gc(strong))) char const *(^libraryNameForIndex)() = ^() {
        NSString *moduleName;
        return [moduleName UTF8String];
    };
}