clang  13.0.0git
DeclObjCCommon.h
Go to the documentation of this file.
1 //===- DeclObjCCommon.h - Classes for representing declarations -*- C++ -*-===//
2 //
3 // Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions.
4 // See https://llvm.org/LICENSE.txt for license information.
5 // SPDX-License-Identifier: Apache-2.0 WITH LLVM-exception
6 //
7 //===----------------------------------------------------------------------===//
8 //
9 // This file contains common ObjC enums and classes used in AST and
10 // Sema.
11 //
12 //===----------------------------------------------------------------------===//
13 
14 #ifndef LLVM_CLANG_AST_DECLOBJC_COMMON_H
15 #define LLVM_CLANG_AST_DECLOBJC_COMMON_H
16 
17 namespace clang {
18 
19 /// ObjCPropertyAttribute::Kind - list of property attributes.
20 /// Keep this list in sync with LLVM's Dwarf.h ApplePropertyAttributes.s
21 namespace ObjCPropertyAttribute {
22 enum Kind {
23  kind_noattr = 0x00,
24  kind_readonly = 0x01,
25  kind_getter = 0x02,
26  kind_assign = 0x04,
28  kind_retain = 0x10,
29  kind_copy = 0x20,
31  kind_setter = 0x80,
32  kind_atomic = 0x100,
33  kind_weak = 0x200,
34  kind_strong = 0x400,
36  /// Indicates that the nullability of the type was spelled with a
37  /// property attribute rather than a type qualifier.
38  kind_nullability = 0x1000,
40  kind_class = 0x4000,
41  kind_direct = 0x8000,
42  // Adding a property should change NumObjCPropertyAttrsBits
43  // Also, don't forget to update the Clang C API at CXObjCPropertyAttrKind and
44  // clang_Cursor_getObjCPropertyAttributes.
45 };
46 } // namespace ObjCPropertyAttribute::Kind
47 
48 enum {
49  /// Number of bits fitting all the property attributes.
51 };
52 
53 } // namespace clang
54 
55 #endif // LLVM_CLANG_AST_DECLOBJC_COMMON_H
clang::ObjCPropertyAttribute::kind_direct
@ kind_direct
Definition: DeclObjCCommon.h:41
clang::ObjCPropertyAttribute::kind_class
@ kind_class
Definition: DeclObjCCommon.h:40
clang::ObjCPropertyAttribute::kind_strong
@ kind_strong
Definition: DeclObjCCommon.h:34
clang::ObjCPropertyAttribute::kind_atomic
@ kind_atomic
Definition: DeclObjCCommon.h:32
clang::ObjCPropertyAttribute::kind_copy
@ kind_copy
Definition: DeclObjCCommon.h:29
clang::ObjCPropertyAttribute::kind_weak
@ kind_weak
Definition: DeclObjCCommon.h:33
clang::ObjCPropertyAttribute::kind_unsafe_unretained
@ kind_unsafe_unretained
Definition: DeclObjCCommon.h:35
clang::ObjCPropertyAttribute::kind_null_resettable
@ kind_null_resettable
Definition: DeclObjCCommon.h:39
clang::NumObjCPropertyAttrsBits
@ NumObjCPropertyAttrsBits
Number of bits fitting all the property attributes.
Definition: DeclObjCCommon.h:50
clang::ObjCPropertyAttribute::kind_readonly
@ kind_readonly
Definition: DeclObjCCommon.h:24
clang::ObjCPropertyAttribute::kind_noattr
@ kind_noattr
Definition: DeclObjCCommon.h:23
clang::ObjCPropertyAttribute::kind_assign
@ kind_assign
Definition: DeclObjCCommon.h:26
clang::ObjCPropertyAttribute::Kind
Kind
Definition: DeclObjCCommon.h:22
clang::ObjCPropertyAttribute::kind_readwrite
@ kind_readwrite
Definition: DeclObjCCommon.h:27
clang
Definition: CalledOnceCheck.h:17
clang::ObjCPropertyAttribute::kind_nonatomic
@ kind_nonatomic
Definition: DeclObjCCommon.h:30
clang::ObjCPropertyAttribute::kind_nullability
@ kind_nullability
Indicates that the nullability of the type was spelled with a property attribute rather than a type q...
Definition: DeclObjCCommon.h:38
clang::ObjCPropertyAttribute::kind_getter
@ kind_getter
Definition: DeclObjCCommon.h:25
clang::ObjCPropertyAttribute::kind_retain
@ kind_retain
Definition: DeclObjCCommon.h:28
clang::ObjCPropertyAttribute::kind_setter
@ kind_setter
Definition: DeclObjCCommon.h:31