3939
4040SWIFT_BEGIN_NULLABILITY_ANNOTATIONS
4141
42- typedef long SwiftInt ;
43- typedef unsigned long SwiftUInt ;
44-
4542typedef struct {
4643 const void * _Nullable data ;
47- long numElements ;
44+ SwiftInt numElements ;
4845} BridgedArrayRef ;
4946
5047typedef struct {
@@ -65,7 +62,7 @@ typedef struct {
6562 void * _Nullable TrailingCommaLoc ;
6663} BridgedTupleTypeElement ;
6764
68- typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedRequirementReprKind : long {
65+ typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedRequirementReprKind : SwiftInt {
6966 /// A type bound T : P, where T is a type that depends on a generic
7067 /// parameter and P is some type that should bound T, either as a concrete
7168 /// supertype or a protocol to which T must conform.
@@ -92,7 +89,7 @@ typedef struct {
9289} BridgedRequirementRepr ;
9390
9491/// Diagnostic severity when reporting diagnostics.
95- typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedDiagnosticSeverity : long {
92+ typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedDiagnosticSeverity : SwiftInt {
9693 BridgedFatalError ,
9794 BridgedError ,
9895 BridgedWarning ,
@@ -102,7 +99,7 @@ typedef enum ENUM_EXTENSIBILITY_ATTR(open) BridgedDiagnosticSeverity : long {
10299
103100typedef void * BridgedDiagnostic ;
104101
105- typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedMacroDefinitionKind : long {
102+ typedef enum ENUM_EXTENSIBILITY_ATTR (open ) BridgedMacroDefinitionKind : SwiftInt {
106103 /// An expanded macro.
107104 BridgedExpandedMacro = 0 ,
108105 /// An external macro, spelled with either the old spelling (Module.Type)
@@ -130,7 +127,7 @@ BridgedDiagnostic SwiftDiagnostic_create(void *diagnosticEngine,
130127 BridgedDiagnosticSeverity severity ,
131128 const void * _Nullable sourceLoc ,
132129 const unsigned char * _Nullable text ,
133- long textLen );
130+ SwiftInt textLen );
134131
135132/// Highlight a source range as part of the diagnostic.
136133void SwiftDiagnostic_highlight (
@@ -141,14 +138,14 @@ void SwiftDiagnostic_fixItReplace(BridgedDiagnostic diag,
141138 const void * _Nullable replaceStartLoc ,
142139 const void * _Nullable replaceEndLoc ,
143140 const unsigned char * _Nullable newText ,
144- long newTextLen );
141+ SwiftInt newTextLen );
145142
146143/// Finish the given diagnostic and emit it.
147144void SwiftDiagnostic_finish (BridgedDiagnostic diag );
148145
149146BridgedIdentifier
150147SwiftASTContext_getIdentifier (void * ctx , const unsigned char * _Nullable str ,
151- long len );
148+ SwiftInt len );
152149
153150void * SwiftImportDecl_create (void * , void * , void * , char , void * ,
154151 BridgedArrayRef , BridgedArrayRef );
@@ -173,11 +170,11 @@ void *SwiftIdentifierExpr_create(void *ctx, BridgedIdentifier base, void *loc);
173170
174171void * SwiftStringLiteralExpr_create (void * ctx ,
175172 const unsigned char * _Nullable string ,
176- long len , void * TokenLoc );
173+ SwiftInt len , void * TokenLoc );
177174
178175void * SwiftIntegerLiteralExpr_create (void * ctx ,
179176 const unsigned char * _Nullable string ,
180- long len , void * TokenLoc );
177+ SwiftInt len , void * TokenLoc );
181178
182179void * SwiftBooleanLiteralExpr_create (void * ctx , _Bool value , void * TokenLoc );
183180
@@ -194,7 +191,7 @@ void *SingleValueStmtExpr_createWithWrappedBranches(void *ctx, void *S,
194191void * IfStmt_create (void * ctx , void * ifLoc , void * cond , void * _Nullable then ,
195192 void * _Nullable elseLoc , void * _Nullable elseStmt );
196193
197- typedef enum ENUM_EXTENSIBILITY_ATTR (open ) ASTNodeKind : long {
194+ typedef enum ENUM_EXTENSIBILITY_ATTR (open ) ASTNodeKind : SwiftInt {
198195 ASTNodeKindExpr ,
199196 ASTNodeKindStmt ,
200197 ASTNodeKindDecl
@@ -208,7 +205,7 @@ struct ASTNodeBridged {
208205void * BraceStmt_create (void * ctx , void * lbloc , BridgedArrayRef elements ,
209206 void * rbloc );
210207
211- void * BridgedSourceLoc_advanced (void * loc , long len );
208+ void * BridgedSourceLoc_advanced (void * loc , SwiftInt len );
212209
213210void * ParamDecl_create (void * ctx , void * loc , void * _Nullable argLoc ,
214211 void * _Nullable argName , void * _Nullable paramLoc ,
@@ -282,7 +279,7 @@ void *GenericParamList_create(void *ctx, void *lAngleLoc,
282279 BridgedArrayRef reqs , void * rAngleLoc );
283280void * GenericTypeParamDecl_create (void * ctx , void * declContext ,
284281 BridgedIdentifier name , void * nameLoc ,
285- void * _Nullable eachLoc , long index ,
282+ void * _Nullable eachLoc , SwiftInt index ,
286283 _Bool isParameterPack );
287284void GenericTypeParamDecl_setInheritedType (void * ctx , void * Param , void * ty );
288285
0 commit comments