@@ -63,26 +63,287 @@ class Ptrdiff_t extends Type {
6363 override string getAPrimaryQlClass ( ) { result = "Ptrdiff_t" }
6464}
6565
66+ /**
67+ * A parent class representing C/C++ a typedef'd `UserType` such as `int8_t`.
68+ */
69+ abstract private class IntegralUnderlyingUserType extends UserType {
70+ IntegralUnderlyingUserType ( ) { this .getUnderlyingType ( ) instanceof IntegralType }
71+ }
72+
73+ abstract private class TFixedWidthIntegralType extends IntegralUnderlyingUserType { }
74+
75+ /**
76+ * A C/C++ fixed-width numeric type, such as `int8_t`.
77+ */
78+ class FixedWidthIntegralType extends TFixedWidthIntegralType {
79+ FixedWidthIntegralType ( ) { this instanceof TFixedWidthIntegralType }
80+ }
81+
82+ abstract private class TMinimumWidthIntegralType extends IntegralUnderlyingUserType { }
83+
84+ /**
85+ * A C/C++ minimum-width numeric type, such as `int_least8_t`.
86+ */
87+ class MinimumWidthIntegralType extends TMinimumWidthIntegralType {
88+ MinimumWidthIntegralType ( ) { this instanceof TMinimumWidthIntegralType }
89+ }
90+
91+ abstract private class TFastestMinimumWidthIntegralType extends IntegralUnderlyingUserType { }
92+
93+ /**
94+ * A C/C++ minimum-width numeric type, representing the fastest integer type with a
95+ * width of at least `N` such as `int_fast8_t`.
96+ */
97+ class FastestMinimumWidthIntegralType extends TFastestMinimumWidthIntegralType {
98+ FastestMinimumWidthIntegralType ( ) { this instanceof TFastestMinimumWidthIntegralType }
99+ }
100+
101+ abstract private class TMaximumWidthIntegralType extends IntegralUnderlyingUserType { }
102+
103+ /**
104+ * A C/C++ maximum-width numeric type, either `intmax_t` or `uintmax_t`.
105+ */
106+ class MaximumWidthIntegralType extends TMaximumWidthIntegralType {
107+ MaximumWidthIntegralType ( ) { this instanceof TMaximumWidthIntegralType }
108+ }
109+
110+ /**
111+ * An enum type based on a fixed-width integer type. For instance, `enum e: uint8_t = { a, b };`
112+ */
113+ class FixedWidthEnumType extends UserType {
114+ FixedWidthEnumType ( ) { this .( Enum ) .getExplicitUnderlyingType ( ) instanceof FixedWidthIntegralType }
115+ }
116+
117+ /**
118+ * The C/C++ `int8_t` type.
119+ */
120+ class Int8_t extends TFixedWidthIntegralType {
121+ Int8_t ( ) { this .hasGlobalOrStdName ( "int8_t" ) }
122+
123+ override string getAPrimaryQlClass ( ) { result = "Int8_t" }
124+ }
125+
126+ /**
127+ * The C/C++ `int16_t` type.
128+ */
129+ class Int16_t extends TFixedWidthIntegralType {
130+ Int16_t ( ) { this .hasGlobalOrStdName ( "int16_t" ) }
131+
132+ override string getAPrimaryQlClass ( ) { result = "Int16_t" }
133+ }
134+
135+ /**
136+ * The C/C++ `int32_t` type.
137+ */
138+ class Int32_t extends TFixedWidthIntegralType {
139+ Int32_t ( ) { this .hasGlobalOrStdName ( "int32_t" ) }
140+
141+ override string getAPrimaryQlClass ( ) { result = "Int32_t" }
142+ }
143+
144+ /**
145+ * The C/C++ `int64_t` type.
146+ */
147+ class Int64_t extends TFixedWidthIntegralType {
148+ Int64_t ( ) { this .hasGlobalOrStdName ( "int64_t" ) }
149+
150+ override string getAPrimaryQlClass ( ) { result = "Int64_t" }
151+ }
152+
153+ /**
154+ * The C/C++ `uint8_t` type.
155+ */
156+ class UInt8_t extends TFixedWidthIntegralType {
157+ UInt8_t ( ) { this .hasGlobalOrStdName ( "uint8_t" ) }
158+
159+ override string getAPrimaryQlClass ( ) { result = "UInt8_t" }
160+ }
161+
162+ /**
163+ * The C/C++ `uint16_t` type.
164+ */
165+ class UInt16_t extends TFixedWidthIntegralType {
166+ UInt16_t ( ) { this .hasGlobalOrStdName ( "uint16_t" ) }
167+
168+ override string getAPrimaryQlClass ( ) { result = "UInt16_t" }
169+ }
170+
171+ /**
172+ * The C/C++ `uint32_t` type.
173+ */
174+ class UInt32_t extends TFixedWidthIntegralType {
175+ UInt32_t ( ) { this .hasGlobalOrStdName ( "uint32_t" ) }
176+
177+ override string getAPrimaryQlClass ( ) { result = "UInt32_t" }
178+ }
179+
180+ /**
181+ * The C/C++ `uint64_t` type.
182+ */
183+ class UInt64_t extends TFixedWidthIntegralType {
184+ UInt64_t ( ) { this .hasGlobalOrStdName ( "uint64_t" ) }
185+
186+ override string getAPrimaryQlClass ( ) { result = "UInt64_t" }
187+ }
188+
189+ /**
190+ * The C/C++ `int_least8_t` type.
191+ */
192+ class Int_least8_t extends TMinimumWidthIntegralType {
193+ Int_least8_t ( ) { this .hasGlobalOrStdName ( "int_least8_t" ) }
194+
195+ override string getAPrimaryQlClass ( ) { result = "Int_least8_t" }
196+ }
197+
198+ /**
199+ * The C/C++ `int_least16_t` type.
200+ */
201+ class Int_least16_t extends TMinimumWidthIntegralType {
202+ Int_least16_t ( ) { this .hasGlobalOrStdName ( "int_least16_t" ) }
203+
204+ override string getAPrimaryQlClass ( ) { result = "Int_least16_t" }
205+ }
206+
207+ /**
208+ * The C/C++ `int_least32_t` type.
209+ */
210+ class Int_least32_t extends TMinimumWidthIntegralType {
211+ Int_least32_t ( ) { this .hasGlobalOrStdName ( "int_least32_t" ) }
212+
213+ override string getAPrimaryQlClass ( ) { result = "Int_least32_t" }
214+ }
215+
216+ /**
217+ * The C/C++ `int_least64_t` type.
218+ */
219+ class Int_least64_t extends TMinimumWidthIntegralType {
220+ Int_least64_t ( ) { this .hasGlobalOrStdName ( "int_least64_t" ) }
221+
222+ override string getAPrimaryQlClass ( ) { result = "Int_least64_t" }
223+ }
224+
225+ /**
226+ * The C/C++ `uint_least8_t` type.
227+ */
228+ class UInt_least8_t extends TMinimumWidthIntegralType {
229+ UInt_least8_t ( ) { this .hasGlobalOrStdName ( "uint_least8_t" ) }
230+
231+ override string getAPrimaryQlClass ( ) { result = "UInt_least8_t" }
232+ }
233+
234+ /**
235+ * The C/C++ `uint_least16_t` type.
236+ */
237+ class UInt_least16_t extends TMinimumWidthIntegralType {
238+ UInt_least16_t ( ) { this .hasGlobalOrStdName ( "uint_least16_t" ) }
239+
240+ override string getAPrimaryQlClass ( ) { result = "UInt_least16_t" }
241+ }
242+
243+ /**
244+ * The C/C++ `uint_least32_t` type.
245+ */
246+ class UInt_least32_t extends TMinimumWidthIntegralType {
247+ UInt_least32_t ( ) { this .hasGlobalOrStdName ( "uint_least32_t" ) }
248+
249+ override string getAPrimaryQlClass ( ) { result = "UInt_least32_t" }
250+ }
251+
252+ /**
253+ * The C/C++ `uint_least64_t` type.
254+ */
255+ class UInt_least64_t extends TMinimumWidthIntegralType {
256+ UInt_least64_t ( ) { this .hasGlobalOrStdName ( "uint_least64_t" ) }
257+
258+ override string getAPrimaryQlClass ( ) { result = "UInt_least64_t" }
259+ }
260+
261+ /**
262+ * The C/C++ `int_fast8_t` type.
263+ */
264+ class Int_fast8_t extends TFastestMinimumWidthIntegralType {
265+ Int_fast8_t ( ) { this .hasGlobalOrStdName ( "int_fast8_t" ) }
266+
267+ override string getAPrimaryQlClass ( ) { result = "Int_fast8_t" }
268+ }
269+
270+ /**
271+ * The C/C++ `int_fast16_t` type.
272+ */
273+ class Int_fast16_t extends TFastestMinimumWidthIntegralType {
274+ Int_fast16_t ( ) { this .hasGlobalOrStdName ( "int_fast16_t" ) }
275+
276+ override string getAPrimaryQlClass ( ) { result = "Int_fast16_t" }
277+ }
278+
279+ /**
280+ * The C/C++ `int_fast32_t` type.
281+ */
282+ class Int_fast32_t extends TFastestMinimumWidthIntegralType {
283+ Int_fast32_t ( ) { this .hasGlobalOrStdName ( "int_fast32_t" ) }
284+
285+ override string getAPrimaryQlClass ( ) { result = "Int_fast32_t" }
286+ }
287+
288+ /**
289+ * The C/C++ `int_fast64_t` type.
290+ */
291+ class Int_fast64_t extends TFastestMinimumWidthIntegralType {
292+ Int_fast64_t ( ) { this .hasGlobalOrStdName ( "int_fast64_t" ) }
293+
294+ override string getAPrimaryQlClass ( ) { result = "Int_fast64_t" }
295+ }
296+
297+ /**
298+ * The C/C++ `uint_fast8_t` type.
299+ */
300+ class UInt_fast8_t extends TFastestMinimumWidthIntegralType {
301+ UInt_fast8_t ( ) { this .hasGlobalOrStdName ( "uint_fast8_t" ) }
302+
303+ override string getAPrimaryQlClass ( ) { result = "UInt_fast8_t" }
304+ }
305+
306+ /**
307+ * The C/C++ `uint_fast16_t` type.
308+ */
309+ class UInt_fast16_t extends TFastestMinimumWidthIntegralType {
310+ UInt_fast16_t ( ) { this .hasGlobalOrStdName ( "uint_fast16_t" ) }
311+
312+ override string getAPrimaryQlClass ( ) { result = "UInt_fast16_t" }
313+ }
314+
315+ /**
316+ * The C/C++ `uint_fast32_t` type.
317+ */
318+ class UInt_fast32_t extends TFastestMinimumWidthIntegralType {
319+ UInt_fast32_t ( ) { this .hasGlobalOrStdName ( "uint_fast32_t" ) }
320+
321+ override string getAPrimaryQlClass ( ) { result = "UInt_fast32_t" }
322+ }
323+
324+ /**
325+ * The C/C++ `uint_fast64_t` type.
326+ */
327+ class UInt_fast64_t extends TFastestMinimumWidthIntegralType {
328+ UInt_fast64_t ( ) { this .hasGlobalOrStdName ( "uint_fast64_t" ) }
329+
330+ override string getAPrimaryQlClass ( ) { result = "UInt_fast64_t" }
331+ }
332+
66333/**
67334 * The C/C++ `intmax_t` type.
68335 */
69- class Intmax_t extends Type {
70- Intmax_t ( ) {
71- this .getUnderlyingType ( ) instanceof IntegralType and
72- this .hasName ( "intmax_t" )
73- }
336+ class Intmax_t extends TMaximumWidthIntegralType {
337+ Intmax_t ( ) { this .hasGlobalOrStdName ( "intmax_t" ) }
74338
75339 override string getAPrimaryQlClass ( ) { result = "Intmax_t" }
76340}
77341
78342/**
79343 * The C/C++ `uintmax_t` type.
80344 */
81- class Uintmax_t extends Type {
82- Uintmax_t ( ) {
83- this .getUnderlyingType ( ) instanceof IntegralType and
84- this .hasName ( "uintmax_t" )
85- }
345+ class Uintmax_t extends TMaximumWidthIntegralType {
346+ Uintmax_t ( ) { this .hasGlobalOrStdName ( "uintmax_t" ) }
86347
87348 override string getAPrimaryQlClass ( ) { result = "Uintmax_t" }
88349}
0 commit comments