34
34
* compatible, thus CINDEX_VERSION_MAJOR is expected to remain stable.
35
35
*/
36
36
#define CINDEX_VERSION_MAJOR 0
37
- #define CINDEX_VERSION_MINOR 49
37
+ #define CINDEX_VERSION_MINOR 50
38
38
39
39
#define CINDEX_VERSION_ENCODE (major , minor ) ( \
40
40
((major) * 10000) \
@@ -180,7 +180,6 @@ typedef struct CXVersion {
180
180
* A negative value indicates that the cursor is not a function declaration.
181
181
*/
182
182
enum CXCursor_ExceptionSpecificationKind {
183
-
184
183
/**
185
184
* The cursor has no exception specification.
186
185
*/
@@ -1334,7 +1333,17 @@ enum CXTranslationUnit_Flags {
1334
1333
*
1335
1334
* The function bodies of the main file are not skipped.
1336
1335
*/
1337
- CXTranslationUnit_LimitSkipFunctionBodiesToPreamble = 0x800
1336
+ CXTranslationUnit_LimitSkipFunctionBodiesToPreamble = 0x800 ,
1337
+
1338
+ /**
1339
+ * Used to indicate that attributed types should be included in CXType.
1340
+ */
1341
+ CXTranslationUnit_IncludeAttributedTypes = 0x1000 ,
1342
+
1343
+ /**
1344
+ * Used to indicate that implicit attributes should be visited.
1345
+ */
1346
+ CXTranslationUnit_VisitImplicitAttributes = 0x2000
1338
1347
};
1339
1348
1340
1349
/**
@@ -2561,7 +2570,25 @@ enum CXCursorKind {
2561
2570
CXCursor_VisibilityAttr = 417 ,
2562
2571
CXCursor_DLLExport = 418 ,
2563
2572
CXCursor_DLLImport = 419 ,
2564
- CXCursor_LastAttr = CXCursor_DLLImport ,
2573
+ CXCursor_NSReturnsRetained = 420 ,
2574
+ CXCursor_NSReturnsNotRetained = 421 ,
2575
+ CXCursor_NSReturnsAutoreleased = 422 ,
2576
+ CXCursor_NSConsumesSelf = 423 ,
2577
+ CXCursor_NSConsumed = 424 ,
2578
+ CXCursor_ObjCException = 425 ,
2579
+ CXCursor_ObjCNSObject = 426 ,
2580
+ CXCursor_ObjCIndependentClass = 427 ,
2581
+ CXCursor_ObjCPreciseLifetime = 428 ,
2582
+ CXCursor_ObjCReturnsInnerPointer = 429 ,
2583
+ CXCursor_ObjCRequiresSuper = 430 ,
2584
+ CXCursor_ObjCRootClass = 431 ,
2585
+ CXCursor_ObjCSubclassingRestricted = 432 ,
2586
+ CXCursor_ObjCExplicitProtocolImpl = 433 ,
2587
+ CXCursor_ObjCDesignatedInitializer = 434 ,
2588
+ CXCursor_ObjCRuntimeVisible = 435 ,
2589
+ CXCursor_ObjCBoxable = 436 ,
2590
+ CXCursor_FlagEnum = 437 ,
2591
+ CXCursor_LastAttr = CXCursor_FlagEnum ,
2565
2592
2566
2593
/* Preprocessing */
2567
2594
CXCursor_PreprocessingDirective = 500 ,
@@ -3268,7 +3295,25 @@ enum CXTypeKind {
3268
3295
CXType_OCLSampler = 157 ,
3269
3296
CXType_OCLEvent = 158 ,
3270
3297
CXType_OCLQueue = 159 ,
3271
- CXType_OCLReserveID = 160
3298
+ CXType_OCLReserveID = 160 ,
3299
+
3300
+ CXType_ObjCObject = 161 ,
3301
+ CXType_ObjCTypeParam = 162 ,
3302
+ CXType_Attributed = 163 ,
3303
+
3304
+ CXType_OCLIntelSubgroupAVCMcePayload = 164 ,
3305
+ CXType_OCLIntelSubgroupAVCImePayload = 165 ,
3306
+ CXType_OCLIntelSubgroupAVCRefPayload = 166 ,
3307
+ CXType_OCLIntelSubgroupAVCSicPayload = 167 ,
3308
+ CXType_OCLIntelSubgroupAVCMceResult = 168 ,
3309
+ CXType_OCLIntelSubgroupAVCImeResult = 169 ,
3310
+ CXType_OCLIntelSubgroupAVCRefResult = 170 ,
3311
+ CXType_OCLIntelSubgroupAVCSicResult = 171 ,
3312
+ CXType_OCLIntelSubgroupAVCImeResultSingleRefStreamout = 172 ,
3313
+ CXType_OCLIntelSubgroupAVCImeResultDualRefStreamout = 173 ,
3314
+ CXType_OCLIntelSubgroupAVCImeSingleRefStreamin = 174 ,
3315
+
3316
+ CXType_OCLIntelSubgroupAVCImeDualRefStreamin = 175
3272
3317
};
3273
3318
3274
3319
/**
@@ -3293,6 +3338,7 @@ enum CXCallingConv {
3293
3338
CXCallingConv_Swift = 13 ,
3294
3339
CXCallingConv_PreserveMost = 14 ,
3295
3340
CXCallingConv_PreserveAll = 15 ,
3341
+ CXCallingConv_AArch64VectorCall = 16 ,
3296
3342
3297
3343
CXCallingConv_Invalid = 100 ,
3298
3344
CXCallingConv_Unexposed = 200
@@ -3629,6 +3675,43 @@ CINDEX_LINKAGE int clang_getNumArgTypes(CXType T);
3629
3675
*/
3630
3676
CINDEX_LINKAGE CXType clang_getArgType (CXType T , unsigned i );
3631
3677
3678
+ /**
3679
+ * Retrieves the base type of the ObjCObjectType.
3680
+ *
3681
+ * If the type is not an ObjC object, an invalid type is returned.
3682
+ */
3683
+ CINDEX_LINKAGE CXType clang_Type_getObjCObjectBaseType (CXType T );
3684
+
3685
+ /**
3686
+ * Retrieve the number of protocol references associated with an ObjC object/id.
3687
+ *
3688
+ * If the type is not an ObjC object, 0 is returned.
3689
+ */
3690
+ CINDEX_LINKAGE unsigned clang_Type_getNumObjCProtocolRefs (CXType T );
3691
+
3692
+ /**
3693
+ * Retrieve the decl for a protocol reference for an ObjC object/id.
3694
+ *
3695
+ * If the type is not an ObjC object or there are not enough protocol
3696
+ * references, an invalid cursor is returned.
3697
+ */
3698
+ CINDEX_LINKAGE CXCursor clang_Type_getObjCProtocolDecl (CXType T , unsigned i );
3699
+
3700
+ /**
3701
+ * Retreive the number of type arguments associated with an ObjC object.
3702
+ *
3703
+ * If the type is not an ObjC object, 0 is returned.
3704
+ */
3705
+ CINDEX_LINKAGE unsigned clang_Type_getNumObjCTypeArgs (CXType T );
3706
+
3707
+ /**
3708
+ * Retrieve a type argument associated with an ObjC object.
3709
+ *
3710
+ * If the type is not an ObjC or the index is not valid,
3711
+ * an invalid type is returned.
3712
+ */
3713
+ CINDEX_LINKAGE CXType clang_Type_getObjCTypeArg (CXType T , unsigned i );
3714
+
3632
3715
/**
3633
3716
* Return 1 if the CXType is a variadic function type, and 0 otherwise.
3634
3717
*/
@@ -3702,6 +3785,33 @@ CINDEX_LINKAGE CXType clang_Type_getNamedType(CXType T);
3702
3785
*/
3703
3786
CINDEX_LINKAGE unsigned clang_Type_isTransparentTagTypedef (CXType T );
3704
3787
3788
+ enum CXTypeNullabilityKind {
3789
+ /**
3790
+ * Values of this type can never be null.
3791
+ */
3792
+ CXTypeNullability_NonNull = 0 ,
3793
+ /**
3794
+ * Values of this type can be null.
3795
+ */
3796
+ CXTypeNullability_Nullable = 1 ,
3797
+ /**
3798
+ * Whether values of this type can be null is (explicitly)
3799
+ * unspecified. This captures a (fairly rare) case where we
3800
+ * can't conclude anything about the nullability of the type even
3801
+ * though it has been considered.
3802
+ */
3803
+ CXTypeNullability_Unspecified = 2 ,
3804
+ /**
3805
+ * Nullability is not applicable to this type.
3806
+ */
3807
+ CXTypeNullability_Invalid = 3
3808
+ };
3809
+
3810
+ /**
3811
+ * Retrieve the nullability kind of a pointer type.
3812
+ */
3813
+ CINDEX_LINKAGE enum CXTypeNullabilityKind clang_Type_getNullability (CXType T );
3814
+
3705
3815
/**
3706
3816
* List the possible error codes for \c clang_Type_getSizeOf,
3707
3817
* \c clang_Type_getAlignOf, \c clang_Type_getOffsetOf and
@@ -3780,6 +3890,13 @@ CINDEX_LINKAGE long long clang_Type_getSizeOf(CXType T);
3780
3890
*/
3781
3891
CINDEX_LINKAGE long long clang_Type_getOffsetOf (CXType T , const char * S );
3782
3892
3893
+ /**
3894
+ * Return the type that was modified by this attributed type.
3895
+ *
3896
+ * If the type is not an attributed type, an invalid type is returned.
3897
+ */
3898
+ CINDEX_LINKAGE CXType clang_Type_getModifiedType (CXType T );
3899
+
3783
3900
/**
3784
3901
* Return the offset of the field represented by the Cursor.
3785
3902
*
@@ -4349,6 +4466,18 @@ typedef enum {
4349
4466
CINDEX_LINKAGE unsigned clang_Cursor_getObjCPropertyAttributes (CXCursor C ,
4350
4467
unsigned reserved );
4351
4468
4469
+ /**
4470
+ * Given a cursor that represents a property declaration, return the
4471
+ * name of the method that implements the getter.
4472
+ */
4473
+ CINDEX_LINKAGE CXString clang_Cursor_getObjCPropertyGetterName (CXCursor C );
4474
+
4475
+ /**
4476
+ * Given a cursor that represents a property declaration, return the
4477
+ * name of the method that implements the setter, if any.
4478
+ */
4479
+ CINDEX_LINKAGE CXString clang_Cursor_getObjCPropertySetterName (CXCursor C );
4480
+
4352
4481
/**
4353
4482
* 'Qualifiers' written next to the return and parameter types in
4354
4483
* Objective-C method declarations.
@@ -5493,10 +5622,15 @@ enum CXCompletionContext {
5493
5622
*/
5494
5623
CXCompletionContext_NaturalLanguage = 1 << 21 ,
5495
5624
5625
+ /**
5626
+ * #include file completions should be included in the results.
5627
+ */
5628
+ CXCompletionContext_IncludedFile = 1 << 22 ,
5629
+
5496
5630
/**
5497
5631
* The current context is unknown, so set all contexts.
5498
5632
*/
5499
- CXCompletionContext_Unknown = ((1 << 22 ) - 1 )
5633
+ CXCompletionContext_Unknown = ((1 << 23 ) - 1 )
5500
5634
};
5501
5635
5502
5636
/**
0 commit comments