24
24
//! * 4.0 - [Documentation](https://kylemayes.github.io/clang-sys/4_0/clang_sys)
25
25
//! * 5.0 - [Documentation](https://kylemayes.github.io/clang-sys/5_0/clang_sys)
26
26
//! * 6.0 - [Documentation](https://kylemayes.github.io/clang-sys/6_0/clang_sys)
27
+ //! * 7.0 - [Documentation](https://kylemayes.github.io/clang-sys/7_0/clang_sys)
27
28
28
29
#![ allow( non_camel_case_types, non_snake_case, non_upper_case_globals) ]
29
30
@@ -322,6 +323,8 @@ cenum! {
322
323
const CXCursor_OMPArraySectionExpr = 147 ,
323
324
/// Only produced by `libclang` 3.9 and later.
324
325
const CXCursor_ObjCAvailabilityCheckExpr = 148 ,
326
+ /// Only produced by `libclang` 7.0 and later.
327
+ const CXCursor_FixedPointLiteral = 149 ,
325
328
const CXCursor_UnexposedStmt = 200 ,
326
329
const CXCursor_LabelStmt = 201 ,
327
330
const CXCursor_CompoundStmt = 202 ,
@@ -628,6 +631,38 @@ cenum! {
628
631
}
629
632
}
630
633
634
+ cenum ! {
635
+ #[ cfg( feature="gte_clang_7_0" ) ]
636
+ enum CXPrintingPolicyProperty {
637
+ const CXPrintingPolicy_Indentation = 0 ,
638
+ const CXPrintingPolicy_SuppressSpecifiers = 1 ,
639
+ const CXPrintingPolicy_SuppressTagKeyword = 2 ,
640
+ const CXPrintingPolicy_IncludeTagDefinition = 3 ,
641
+ const CXPrintingPolicy_SuppressScope = 4 ,
642
+ const CXPrintingPolicy_SuppressUnwrittenScope = 5 ,
643
+ const CXPrintingPolicy_SuppressInitializers = 6 ,
644
+ const CXPrintingPolicy_ConstantArraySizeAsWritten = 7 ,
645
+ const CXPrintingPolicy_AnonymousTagLocations = 8 ,
646
+ const CXPrintingPolicy_SuppressStrongLifetime = 9 ,
647
+ const CXPrintingPolicy_SuppressLifetimeQualifiers = 10 ,
648
+ const CXPrintingPolicy_SuppressTemplateArgsInCXXConstructors = 11 ,
649
+ const CXPrintingPolicy_Bool = 12 ,
650
+ const CXPrintingPolicy_Restrict = 13 ,
651
+ const CXPrintingPolicy_Alignof = 14 ,
652
+ const CXPrintingPolicy_UnderscoreAlignof = 15 ,
653
+ const CXPrintingPolicy_UseVoidForZeroParams = 16 ,
654
+ const CXPrintingPolicy_TerseOutput = 17 ,
655
+ const CXPrintingPolicy_PolishForDeclaration = 18 ,
656
+ const CXPrintingPolicy_Half = 19 ,
657
+ const CXPrintingPolicy_MSWChar = 20 ,
658
+ const CXPrintingPolicy_IncludeNewlines = 21 ,
659
+ const CXPrintingPolicy_MSVCFormatting = 22 ,
660
+ const CXPrintingPolicy_ConstantsAsWritten = 23 ,
661
+ const CXPrintingPolicy_SuppressImplicitBase = 24 ,
662
+ const CXPrintingPolicy_FullyQualifiedName = 25 ,
663
+ }
664
+ }
665
+
631
666
cenum ! {
632
667
enum CXRefQualifierKind {
633
668
const CXRefQualifier_None = 0 ,
@@ -745,6 +780,18 @@ cenum! {
745
780
const CXType_Half = 31 ,
746
781
/// Only produced by `libclang` 6.0 and later.
747
782
const CXType_Float16 = 32 ,
783
+ /// Only produced by `libclang` 7.0 and later.
784
+ const CXType_ShortAccum = 33 ,
785
+ /// Only produced by `libclang` 7.0 and later.
786
+ const CXType_Accum = 34 ,
787
+ /// Only produced by `libclang` 7.0 and later.
788
+ const CXType_LongAccum = 35 ,
789
+ /// Only produced by `libclang` 7.0 and later.
790
+ const CXType_UShortAccum = 36 ,
791
+ /// Only produced by `libclang` 7.0 and later.
792
+ const CXType_UAccum = 37 ,
793
+ /// Only produced by `libclang` 7.0 and later.
794
+ const CXType_ULongAccum = 38 ,
748
795
const CXType_Complex = 100 ,
749
796
const CXType_Pointer = 101 ,
750
797
const CXType_BlockPointer = 102 ,
@@ -911,6 +958,8 @@ cenum! {
911
958
const CXCodeComplete_IncludeMacros = 1 ;
912
959
const CXCodeComplete_IncludeCodePatterns = 2 ;
913
960
const CXCodeComplete_IncludeBriefComments = 4 ;
961
+ const CXCodeComplete_SkipPreamble = 8 ;
962
+ const CXCodeComplete_IncludeCompletionsWithFixIts = 16 ;
914
963
}
915
964
}
916
965
@@ -1032,6 +1081,22 @@ cenum! {
1032
1081
}
1033
1082
}
1034
1083
1084
+ cenum ! {
1085
+ #[ cfg( feature="gte_clang_7_0" ) ]
1086
+ enum CXSymbolRole {
1087
+ const CXSymbolRole_None = 0 ;
1088
+ const CXSymbolRole_Declaration = 1 ;
1089
+ const CXSymbolRole_Definition = 2 ;
1090
+ const CXSymbolRole_Reference = 4 ;
1091
+ const CXSymbolRole_Read = 8 ;
1092
+ const CXSymbolRole_Write = 16 ;
1093
+ const CXSymbolRole_Call = 32 ;
1094
+ const CXSymbolRole_Dynamic = 64 ;
1095
+ const CXSymbolRole_AddressOf = 128 ;
1096
+ const CXSymbolRole_Implicit = 256 ;
1097
+ }
1098
+ }
1099
+
1035
1100
cenum ! {
1036
1101
enum CXTranslationUnit_Flags {
1037
1102
const CXTranslationUnit_None = 0 ;
@@ -1049,6 +1114,8 @@ cenum! {
1049
1114
const CXTranslationUnit_KeepGoing = 512 ;
1050
1115
#[ cfg( feature="gte_clang_5_0" ) ]
1051
1116
const CXTranslationUnit_SingleFileParse = 1024 ;
1117
+ #[ cfg( feature="gte_clang_7_0" ) ]
1118
+ const CXTranslationUnit_LimitSkipFunctionBodiesToPreamble = 2048 ;
1052
1119
}
1053
1120
}
1054
1121
@@ -1077,6 +1144,8 @@ opaque!(CXIdxClientFile);
1077
1144
opaque ! ( CXIndex ) ;
1078
1145
opaque ! ( CXIndexAction ) ;
1079
1146
opaque ! ( CXModule ) ;
1147
+ #[ cfg( feature="gte_clang_7_0" ) ]
1148
+ opaque ! ( CXPrintingPolicy ) ;
1080
1149
opaque ! ( CXRemapping ) ;
1081
1150
#[ cfg( feature="gte_clang_5_0" ) ]
1082
1151
opaque ! ( CXTargetInfo ) ;
@@ -1220,6 +1289,8 @@ pub struct CXIdxEntityRefInfo {
1220
1289
pub referencedEntity : * const CXIdxEntityInfo ,
1221
1290
pub parentEntity : * const CXIdxEntityInfo ,
1222
1291
pub container : * const CXIdxContainerInfo ,
1292
+ #[ cfg( feature="gte_clang_7_0" ) ]
1293
+ pub role : CXSymbolRole ,
1223
1294
}
1224
1295
1225
1296
default ! ( CXIdxEntityRefInfo ) ;
@@ -1576,6 +1647,8 @@ link! {
1576
1647
pub fn clang_EvalResult_isUnsignedInt( result: CXEvalResult ) -> c_uint;
1577
1648
#[ cfg( feature="gte_clang_3_6" ) ]
1578
1649
pub fn clang_File_isEqual( left: CXFile , right: CXFile ) -> c_int;
1650
+ #[ cfg( feature="gte_clang_7_0" ) ]
1651
+ pub fn clang_File_tryGetRealPathName( file: CXFile ) -> CXString ;
1579
1652
pub fn clang_IndexAction_create( index: CXIndex ) -> CXIndexAction ;
1580
1653
pub fn clang_IndexAction_dispose( index: CXIndexAction ) ;
1581
1654
pub fn clang_Location_isFromMainFile( location: CXSourceLocation ) -> c_int;
@@ -1587,6 +1660,12 @@ link! {
1587
1660
pub fn clang_Module_getParent( module: CXModule ) -> CXModule ;
1588
1661
pub fn clang_Module_getTopLevelHeader( tu: CXTranslationUnit , module: CXModule , index: c_uint) -> CXFile ;
1589
1662
pub fn clang_Module_isSystem( module: CXModule ) -> c_int;
1663
+ #[ cfg( feature="gte_clang_7_0" ) ]
1664
+ pub fn clang_PrintingPolicy_dispose( policy: CXPrintingPolicy ) ;
1665
+ #[ cfg( feature="gte_clang_7_0" ) ]
1666
+ pub fn clang_PrintingPolicy_getProperty( policy: CXPrintingPolicy , property: CXPrintingPolicyProperty ) -> c_uint;
1667
+ #[ cfg( feature="gte_clang_7_0" ) ]
1668
+ pub fn clang_PrintingPolicy_setProperty( policy: CXPrintingPolicy , property: CXPrintingPolicyProperty , value: c_uint) ;
1590
1669
pub fn clang_Range_isNull( range: CXSourceRange ) -> c_int;
1591
1670
#[ cfg( feature="gte_clang_5_0" ) ]
1592
1671
pub fn clang_TargetInfo_dispose( info: CXTargetInfo ) ;
@@ -1678,7 +1757,11 @@ link! {
1678
1757
pub fn clang_getCompletionChunkCompletionString( string: CXCompletionString , index: c_uint) -> CXCompletionString ;
1679
1758
pub fn clang_getCompletionChunkKind( string: CXCompletionString , index: c_uint) -> CXCompletionChunkKind ;
1680
1759
pub fn clang_getCompletionChunkText( string: CXCompletionString , index: c_uint) -> CXString ;
1760
+ #[ cfg( feature="gte_clang_7_0" ) ]
1761
+ pub fn clang_getCompletionFixIt( results: * mut CXCodeCompleteResults , completion_index: c_uint, fixit_index: c_uint, range: * mut CXSourceRange ) -> CXString ;
1681
1762
pub fn clang_getCompletionNumAnnotations( string: CXCompletionString ) -> c_uint;
1763
+ #[ cfg( feature="gte_clang_7_0" ) ]
1764
+ pub fn clang_getCompletionNumFixIts( results: * mut CXCodeCompleteResults , completion_index: c_uint) -> c_uint;
1682
1765
pub fn clang_getCompletionParent( string: CXCompletionString , kind: * mut CXCursorKind ) -> CXString ;
1683
1766
pub fn clang_getCompletionPriority( string: CXCompletionString ) -> c_uint;
1684
1767
pub fn clang_getCursor( tu: CXTranslationUnit , location: CXSourceLocation ) -> CXCursor ;
@@ -1696,6 +1779,10 @@ link! {
1696
1779
pub fn clang_getCursorLinkage( cursor: CXCursor ) -> CXLinkageKind ;
1697
1780
pub fn clang_getCursorLocation( cursor: CXCursor ) -> CXSourceLocation ;
1698
1781
pub fn clang_getCursorPlatformAvailability( cursor: CXCursor , deprecated: * mut c_int, deprecated_message: * mut CXString , unavailable: * mut c_int, unavailable_message: * mut CXString , availability: * mut CXPlatformAvailability , n_availability: c_int) -> c_int;
1782
+ #[ cfg( feature="gte_clang_7_0" ) ]
1783
+ pub fn clang_getCursorPrettyPrinted( cursor: CXCursor , policy: CXPrintingPolicy ) -> CXString ;
1784
+ #[ cfg( feature="gte_clang_7_0" ) ]
1785
+ pub fn clang_getCursorPrintingPolicy( cursor: CXCursor ) -> CXPrintingPolicy ;
1699
1786
pub fn clang_getCursorReferenceNameRange( cursor: CXCursor , flags: CXNameRefFlags , index: c_uint) -> CXSourceRange ;
1700
1787
pub fn clang_getCursorReferenced( cursor: CXCursor ) -> CXCursor ;
1701
1788
pub fn clang_getCursorResultType( cursor: CXCursor ) -> CXType ;
@@ -1811,6 +1898,8 @@ link! {
1811
1898
pub fn clang_isFileMultipleIncludeGuarded( tu: CXTranslationUnit , file: CXFile ) -> c_uint;
1812
1899
pub fn clang_isFunctionTypeVariadic( type_: CXType ) -> c_uint;
1813
1900
pub fn clang_isInvalid( kind: CXCursorKind ) -> c_uint;
1901
+ #[ cfg( feature="gte_clang_7_0" ) ]
1902
+ pub fn clang_isInvalidDeclaration( cursor: CXCursor ) -> c_uint;
1814
1903
pub fn clang_isPODType( type_: CXType ) -> c_uint;
1815
1904
pub fn clang_isPreprocessing( kind: CXCursorKind ) -> c_uint;
1816
1905
pub fn clang_isReference( kind: CXCursorKind ) -> c_uint;
0 commit comments