xref: /minix3/external/bsd/llvm/dist/clang/test/SemaObjCXX/arc-system-header.mm (revision 0a6a1f1d05b60e214de2f05a7310ddd1f0e590e7)
1f4a2713aSLionel Sambuc// RUN: %clang_cc1 -fobjc-arc -isystem %S/Inputs %s -verify
2f4a2713aSLionel Sambuc
3f4a2713aSLionel Sambuc#include <arc-system-header.h>
4f4a2713aSLionel Sambuc
5f4a2713aSLionel Sambucvoid f(A* a) {
6f4a2713aSLionel Sambuc  a->data.void_ptr = 0;
7f4a2713aSLionel Sambuc  a->data.a_b.b = 0; // expected-error{{'a_b' is unavailable: this system field has retaining ownership}}
8f4a2713aSLionel Sambuc}
9*0a6a1f1dSLionel Sambuc// expected-note@arc-system-header.h:10{{'a_b' has been explicitly marked unavailable here}}
10