diff options
| author | Akira Hatanaka <ahatanaka@apple.com> | 2018-03-13 23:37:51 +0000 |
|---|---|---|
| committer | Akira Hatanaka <ahatanaka@apple.com> | 2018-03-13 23:37:51 +0000 |
| commit | ceb66521ba155ad250e54f8142a2034af7ab3210 (patch) | |
| tree | 48073dd3e6c896d6e4c9e6f9a704b31ebff30c76 /clang/test/CodeGenObjC/Inputs | |
| parent | 48ffd5cc6e5bb1daef34ffefbc919a05c5e1f925 (diff) | |
| download | bcm5719-llvm-ceb66521ba155ad250e54f8142a2034af7ab3210.tar.gz bcm5719-llvm-ceb66521ba155ad250e54f8142a2034af7ab3210.zip | |
Check that a field is not annotated with attribute "unavailable" before
setting the NonTrivialToPrimitive* flags of a record.
Union fields that have non-trivial Objective-C ownership qualifications
are normally not legal, but if the union is declared in a system header,
the fields are annotated with attribute "unavailable".
rdar://problem/38431072
llvm-svn: 327464
Diffstat (limited to 'clang/test/CodeGenObjC/Inputs')
| -rw-r--r-- | clang/test/CodeGenObjC/Inputs/strong_in_union.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/clang/test/CodeGenObjC/Inputs/strong_in_union.h b/clang/test/CodeGenObjC/Inputs/strong_in_union.h new file mode 100644 index 00000000000..abe4549055c --- /dev/null +++ b/clang/test/CodeGenObjC/Inputs/strong_in_union.h @@ -0,0 +1,10 @@ +#ifndef STRONG_IN_UNION_H +#define STRONG_IN_UNION_H +#pragma clang system_header + +typedef union { + id f0; + int *f1; +} U; + +#endif // STRONG_IN_UNION_H |

