diff options
author | John McCall <rjmccall@apple.com> | 2013-02-12 02:08:12 +0000 |
---|---|---|
committer | John McCall <rjmccall@apple.com> | 2013-02-12 02:08:12 +0000 |
commit | a2905ea609c8ed1bf41a6b917358983d9f26dc6d (patch) | |
tree | d07cbe155511ffec0b851e7b42d515c5d56b1b6d /test | |
parent | 9dd74c5504c743c96ea3a1d691d6a75ec3a98147 (diff) |
Perform placeholder conversions on the controller of a _Generic
expression.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174930 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test')
-rw-r--r-- | test/SemaObjC/generic-selection.m | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/test/SemaObjC/generic-selection.m b/test/SemaObjC/generic-selection.m new file mode 100644 index 0000000000..70c77dc45d --- /dev/null +++ b/test/SemaObjC/generic-selection.m @@ -0,0 +1,17 @@ +// RUN: %clang_cc1 -fsyntax-only -verify %s +// expected-no-diagnostics + +__attribute__((objc_root_class)) +@interface Root { + Class isa; +} +@end + +@interface A +@property (strong) id x; +@end + +// rdar://13193560 +void test0(A *a) { + int kind = _Generic(a.x, id : 0, int : 1, float : 2); +} |