Mercurial > projects > ldc
annotate dmd/mtype.h @ 1187:a95fc9fcad5c
Make sure -defaultlib and -debuglib don't get cut off if longer than 63 chars,
and clean up some overly verbose code.
author | Frits van Bommel <fvbommel wxs.nl> |
---|---|
date | Wed, 01 Apr 2009 00:52:31 +0200 |
parents | a6dbd571d417 |
children | 3251ce06c820 |
rev | line source |
---|---|
159 | 1 |
2 // Compiler implementation of the D programming language | |
3 // Copyright (c) 1999-2007 by Digital Mars | |
4 // All Rights Reserved | |
5 // written by Walter Bright | |
6 // http://www.digitalmars.com | |
7 // License for redistribution is by either the Artistic License | |
8 // in artistic.txt, or the GNU General Public License in gnu.txt. | |
9 // See the included readme.txt for details. | |
10 | |
11 #ifndef DMD_MTYPE_H | |
12 #define DMD_MTYPE_H | |
13 | |
14 #ifdef __DMC__ | |
15 #pragma once | |
16 #endif /* __DMC__ */ | |
17 | |
18 #include "root.h" | |
19 #include "stringtable.h" | |
20 | |
21 #include "arraytypes.h" | |
22 #include "expression.h" | |
23 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
24 #if IN_LLVM |
173
db9890b3fb64
[svn r189] moving IR data back into DMD frontend nodes
ChristianK
parents:
162
diff
changeset
|
25 // llvm |
1184
a6dbd571d417
Moved ir/irtype.* into ir/irdtype.*.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1147
diff
changeset
|
26 #include "../ir/irdtype.h" |
1051
dc608dc33081
Make IrFuncTy a member of TypeFunction. Reset between modules compiled in the
Christian Kamm <kamm incasoftware de>
parents:
1029
diff
changeset
|
27 #include "../ir/irfuncty.h" |
938
a904cc9bc064
Convert struct arg to integer when passing inreg to make sure LLVM doesn't
Christian Kamm <kamm incasoftware de>
parents:
930
diff
changeset
|
28 namespace llvm { class Type; } |
1147
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
29 struct Ir; |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
30 #endif |
173
db9890b3fb64
[svn r189] moving IR data back into DMD frontend nodes
ChristianK
parents:
162
diff
changeset
|
31 |
159 | 32 struct Scope; |
33 struct Identifier; | |
34 struct Expression; | |
35 struct StructDeclaration; | |
36 struct ClassDeclaration; | |
37 struct VarDeclaration; | |
38 struct EnumDeclaration; | |
39 struct TypedefDeclaration; | |
40 struct TypeInfoDeclaration; | |
41 struct Dsymbol; | |
42 struct TemplateInstance; | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
43 struct CppMangleState; |
159 | 44 enum LINK; |
45 | |
46 struct TypeBasic; | |
47 struct HdrGenState; | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
48 struct Argument; |
159 | 49 |
50 // Back end | |
51 #if IN_GCC | |
52 union tree_node; typedef union tree_node TYPE; | |
53 typedef TYPE type; | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
54 #endif |
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
55 |
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
56 #if IN_DMD |
159 | 57 typedef struct TYPE type; |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
58 struct Symbol; |
159 | 59 #endif |
60 | |
61 enum TY | |
62 { | |
63 Tarray, // dynamic array | |
64 Tsarray, // static array | |
65 Taarray, // associative array | |
66 Tpointer, | |
67 Treference, | |
68 Tfunction, | |
69 Tident, | |
70 Tclass, | |
71 Tstruct, | |
72 Tenum, | |
73 Ttypedef, | |
74 Tdelegate, | |
75 | |
76 Tnone, | |
77 Tvoid, | |
78 Tint8, | |
79 Tuns8, | |
80 Tint16, | |
81 Tuns16, | |
82 Tint32, | |
83 Tuns32, | |
84 Tint64, | |
85 Tuns64, | |
86 Tfloat32, | |
87 Tfloat64, | |
88 Tfloat80, | |
89 | |
90 Timaginary32, | |
91 Timaginary64, | |
92 Timaginary80, | |
93 | |
94 Tcomplex32, | |
95 Tcomplex64, | |
96 Tcomplex80, | |
97 | |
98 Tbit, | |
99 Tbool, | |
100 Tchar, | |
101 Twchar, | |
102 Tdchar, | |
103 | |
104 Terror, | |
105 Tinstance, | |
106 Ttypeof, | |
107 Ttuple, | |
108 Tslice, | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
109 Treturn, |
159 | 110 TMAX |
111 }; | |
112 | |
113 #define Tascii Tchar | |
114 | |
115 extern int Tsize_t; | |
116 extern int Tptrdiff_t; | |
117 | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
118 |
159 | 119 struct Type : Object |
120 { | |
121 TY ty; | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
122 unsigned char mod; // modifiers MODxxxx |
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
123 /* pick this order of numbers so switch statements work better |
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
124 */ |
159 | 125 #define MODconst 1 // type is const |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
126 #define MODinvariant 4 // type is invariant |
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
127 #define MODshared 2 // type is shared |
159 | 128 char *deco; |
129 Type *pto; // merged pointer to this type | |
130 Type *rto; // reference to this type | |
131 Type *arrayof; // array of this type | |
132 TypeInfoDeclaration *vtinfo; // TypeInfo object for this Type | |
133 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
134 #if IN_DMD |
159 | 135 type *ctype; // for back end |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
136 #endif |
159 | 137 |
138 #define tvoid basic[Tvoid] | |
139 #define tint8 basic[Tint8] | |
140 #define tuns8 basic[Tuns8] | |
141 #define tint16 basic[Tint16] | |
142 #define tuns16 basic[Tuns16] | |
143 #define tint32 basic[Tint32] | |
144 #define tuns32 basic[Tuns32] | |
145 #define tint64 basic[Tint64] | |
146 #define tuns64 basic[Tuns64] | |
147 #define tfloat32 basic[Tfloat32] | |
148 #define tfloat64 basic[Tfloat64] | |
149 #define tfloat80 basic[Tfloat80] | |
150 | |
151 #define timaginary32 basic[Timaginary32] | |
152 #define timaginary64 basic[Timaginary64] | |
153 #define timaginary80 basic[Timaginary80] | |
154 | |
155 #define tcomplex32 basic[Tcomplex32] | |
156 #define tcomplex64 basic[Tcomplex64] | |
157 #define tcomplex80 basic[Tcomplex80] | |
158 | |
159 #define tbit basic[Tbit] | |
160 #define tbool basic[Tbool] | |
161 #define tchar basic[Tchar] | |
162 #define twchar basic[Twchar] | |
163 #define tdchar basic[Tdchar] | |
164 | |
165 // Some special types | |
166 #define tshiftcnt tint32 // right side of shift expression | |
167 // #define tboolean tint32 // result of boolean expression | |
168 #define tboolean tbool // result of boolean expression | |
169 #define tindex tint32 // array/ptr index | |
170 static Type *tvoidptr; // void* | |
171 #define terror basic[Terror] // for error recovery | |
172 | |
173 #define tsize_t basic[Tsize_t] // matches size_t alias | |
174 #define tptrdiff_t basic[Tptrdiff_t] // matches ptrdiff_t alias | |
175 #define thash_t tsize_t // matches hash_t alias | |
176 | |
177 static ClassDeclaration *typeinfo; | |
178 static ClassDeclaration *typeinfoclass; | |
179 static ClassDeclaration *typeinfointerface; | |
180 static ClassDeclaration *typeinfostruct; | |
181 static ClassDeclaration *typeinfotypedef; | |
182 static ClassDeclaration *typeinfopointer; | |
183 static ClassDeclaration *typeinfoarray; | |
184 static ClassDeclaration *typeinfostaticarray; | |
185 static ClassDeclaration *typeinfoassociativearray; | |
186 static ClassDeclaration *typeinfoenum; | |
187 static ClassDeclaration *typeinfofunction; | |
188 static ClassDeclaration *typeinfodelegate; | |
189 static ClassDeclaration *typeinfotypelist; | |
190 | |
191 static Type *basic[TMAX]; | |
192 static unsigned char mangleChar[TMAX]; | |
193 static StringTable stringtable; | |
194 | |
195 // These tables are for implicit conversion of binary ops; | |
196 // the indices are the type of operand one, followed by operand two. | |
197 static unsigned char impcnvResult[TMAX][TMAX]; | |
198 static unsigned char impcnvType1[TMAX][TMAX]; | |
199 static unsigned char impcnvType2[TMAX][TMAX]; | |
200 | |
201 // If !=0, give warning on implicit conversion | |
202 static unsigned char impcnvWarn[TMAX][TMAX]; | |
203 | |
204 Type(TY ty, Type *next); | |
205 virtual Type *syntaxCopy(); | |
206 int equals(Object *o); | |
207 int dyncast() { return DYNCAST_TYPE; } // kludge for template.isType() | |
208 int covariant(Type *t); | |
209 char *toChars(); | |
210 static char needThisPrefix(); | |
1147
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
211 #if IN_LLVM |
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
212 static void init(Ir*); |
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
213 #else |
159 | 214 static void init(); |
1147
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
215 #endif |
159 | 216 d_uns64 size(); |
217 virtual d_uns64 size(Loc loc); | |
218 virtual unsigned alignsize(); | |
219 virtual Type *semantic(Loc loc, Scope *sc); | |
220 virtual void toDecoBuffer(OutBuffer *buf); | |
221 Type *merge(); | |
222 virtual void toCBuffer(OutBuffer *buf, Identifier *ident, HdrGenState *hgs); | |
223 virtual void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
224 void toCBuffer3(OutBuffer *buf, HdrGenState *hgs, int mod); | |
225 virtual int isbit(); | |
226 virtual int isintegral(); | |
227 virtual int isfloating(); // real, imaginary, or complex | |
228 virtual int isreal(); | |
229 virtual int isimaginary(); | |
230 virtual int iscomplex(); | |
231 virtual int isscalar(); | |
232 virtual int isunsigned(); | |
233 virtual int isauto(); | |
234 virtual int isString(); | |
235 virtual int checkBoolean(); // if can be converted to boolean value | |
236 void checkDeprecated(Loc loc, Scope *sc); | |
237 Type *pointerTo(); | |
238 Type *referenceTo(); | |
239 Type *arrayOf(); | |
240 virtual Dsymbol *toDsymbol(Scope *sc); | |
241 virtual Type *toBasetype(); | |
242 virtual int isBaseOf(Type *t, int *poffset); | |
243 virtual MATCH implicitConvTo(Type *to); | |
244 virtual ClassDeclaration *isClassHandle(); | |
245 virtual Expression *getProperty(Loc loc, Identifier *ident); | |
246 virtual Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
247 virtual unsigned memalign(unsigned salign); | |
248 virtual Expression *defaultInit(Loc loc = 0); | |
249 virtual int isZeroInit(); // if initializer is 0 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
250 #if IN_DMD |
159 | 251 virtual dt_t **toDt(dt_t **pdt); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
252 #endif |
159 | 253 Identifier *getTypeInfoIdent(int internal); |
254 virtual MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
255 virtual void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); | |
256 Expression *getInternalTypeInfo(Scope *sc); | |
257 Expression *getTypeInfo(Scope *sc); | |
258 virtual TypeInfoDeclaration *getTypeInfoDeclaration(); | |
259 virtual int builtinTypeInfo(); | |
260 virtual Type *reliesOnTident(); | |
261 virtual Expression *toExpression(); | |
262 virtual int hasPointers(); | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
263 Type *next; |
159 | 264 Type *nextOf() { return next; } |
265 | |
266 static void error(Loc loc, const char *format, ...); | |
1103
b30fe7e1dbb9
- Updated to DMD frontend 1.041.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1051
diff
changeset
|
267 static void warning(Loc loc, const char *format, ...); |
159 | 268 |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
269 #if IN_DMD |
159 | 270 // For backend |
271 virtual unsigned totym(); | |
272 virtual type *toCtype(); | |
273 virtual type *toCParamtype(); | |
274 virtual Symbol *toSymbol(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
275 #endif |
159 | 276 |
277 // For eliminating dynamic_cast | |
278 virtual TypeBasic *isTypeBasic(); | |
173
db9890b3fb64
[svn r189] moving IR data back into DMD frontend nodes
ChristianK
parents:
162
diff
changeset
|
279 |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
280 #if IN_LLVM |
663
6aaa3d3c1183
First part of rename to LDC.
Christian Kamm <kamm incasoftware de>
parents:
658
diff
changeset
|
281 // LDC |
1184
a6dbd571d417
Moved ir/irtype.* into ir/irdtype.*.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1147
diff
changeset
|
282 IrDType ir; |
1147
dbe4af57b240
Changed use of toObjFile to a new codegen method.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1146
diff
changeset
|
283 static Ir* sir; |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
284 #endif |
159 | 285 }; |
286 | |
287 struct TypeBasic : Type | |
288 { | |
658
50383e476c7e
Upgraded frontend to DMD 1.035
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
508
diff
changeset
|
289 const char *dstring; |
50383e476c7e
Upgraded frontend to DMD 1.035
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
508
diff
changeset
|
290 const char *cstring; |
159 | 291 unsigned flags; |
292 | |
293 TypeBasic(TY ty); | |
294 Type *syntaxCopy(); | |
295 d_uns64 size(Loc loc); | |
296 unsigned alignsize(); | |
297 Expression *getProperty(Loc loc, Identifier *ident); | |
298 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
299 char *toChars(); | |
300 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
301 int isintegral(); | |
302 int isbit(); | |
303 int isfloating(); | |
304 int isreal(); | |
305 int isimaginary(); | |
306 int iscomplex(); | |
307 int isscalar(); | |
308 int isunsigned(); | |
309 MATCH implicitConvTo(Type *to); | |
310 Expression *defaultInit(Loc loc); | |
311 int isZeroInit(); | |
312 int builtinTypeInfo(); | |
313 | |
314 // For eliminating dynamic_cast | |
315 TypeBasic *isTypeBasic(); | |
316 }; | |
317 | |
318 struct TypeArray : Type | |
319 { | |
320 TypeArray(TY ty, Type *next); | |
321 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
322 }; | |
323 | |
324 // Static array, one with a fixed dimension | |
325 struct TypeSArray : TypeArray | |
326 { | |
327 Expression *dim; | |
328 | |
329 TypeSArray(Type *t, Expression *dim); | |
330 Type *syntaxCopy(); | |
331 d_uns64 size(Loc loc); | |
332 unsigned alignsize(); | |
333 Type *semantic(Loc loc, Scope *sc); | |
334 void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); | |
335 void toDecoBuffer(OutBuffer *buf); | |
336 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
337 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
338 int isString(); | |
339 int isZeroInit(); | |
340 unsigned memalign(unsigned salign); | |
341 MATCH implicitConvTo(Type *to); | |
342 Expression *defaultInit(Loc loc); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
343 #if IN_DMD |
159 | 344 dt_t **toDt(dt_t **pdt); |
345 dt_t **toDtElem(dt_t **pdt, Expression *e); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
346 #endif |
159 | 347 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); |
348 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
349 Expression *toExpression(); | |
350 int hasPointers(); | |
351 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
352 #if IN_DMD |
159 | 353 type *toCtype(); |
354 type *toCParamtype(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
355 #endif |
159 | 356 }; |
357 | |
358 // Dynamic array, no dimension | |
359 struct TypeDArray : TypeArray | |
360 { | |
361 TypeDArray(Type *t); | |
362 Type *syntaxCopy(); | |
363 d_uns64 size(Loc loc); | |
364 unsigned alignsize(); | |
365 Type *semantic(Loc loc, Scope *sc); | |
366 void toDecoBuffer(OutBuffer *buf); | |
367 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
368 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
369 int isString(); | |
370 int isZeroInit(); | |
371 int checkBoolean(); | |
372 MATCH implicitConvTo(Type *to); | |
373 Expression *defaultInit(Loc loc); | |
374 int builtinTypeInfo(); | |
375 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
376 int hasPointers(); | |
377 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
378 #if IN_DMD |
159 | 379 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
380 #endif |
159 | 381 }; |
382 | |
383 struct TypeAArray : TypeArray | |
384 { | |
385 Type *index; // key type for type checking | |
386 Type *key; // actual key type | |
387 | |
388 TypeAArray(Type *t, Type *index); | |
389 Type *syntaxCopy(); | |
390 d_uns64 size(Loc loc); | |
391 Type *semantic(Loc loc, Scope *sc); | |
336 | 392 void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); |
159 | 393 void toDecoBuffer(OutBuffer *buf); |
394 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
395 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
396 Expression *defaultInit(Loc loc); | |
397 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
211
f66219e0d530
[svn r227] Fixed: crash in lifetime.d when resizing array of AAs by .length assignment.
lindquist
parents:
173
diff
changeset
|
398 int isZeroInit(); |
159 | 399 int checkBoolean(); |
400 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
401 int hasPointers(); | |
402 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
403 #if IN_DMD |
159 | 404 // Back end |
758
f04dde6e882c
Added initial D2 support, D2 frontend and changes to codegen to make things compile.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
723
diff
changeset
|
405 Symbol *aaGetSymbol(const char *func, int flags); |
159 | 406 |
407 type *toCtype(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
408 #endif |
159 | 409 }; |
410 | |
411 struct TypePointer : Type | |
412 { | |
413 TypePointer(Type *t); | |
414 Type *syntaxCopy(); | |
415 Type *semantic(Loc loc, Scope *sc); | |
416 d_uns64 size(Loc loc); | |
417 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
418 MATCH implicitConvTo(Type *to); | |
419 int isscalar(); | |
663
6aaa3d3c1183
First part of rename to LDC.
Christian Kamm <kamm incasoftware de>
parents:
658
diff
changeset
|
420 // LDC: pointers are unsigned |
411
3545f9eddbfc
Switch TypePointer::isunsigned from false to true, so CmpExp::toElem chooses the right operand for pointer comparisons.
Christian Kamm <kamm incasoftware de>
parents:
379
diff
changeset
|
421 int isunsigned() { return TRUE; }; |
159 | 422 Expression *defaultInit(Loc loc); |
423 int isZeroInit(); | |
424 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
425 int hasPointers(); | |
426 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
427 #if IN_DMD |
159 | 428 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
429 #endif |
159 | 430 }; |
431 | |
432 struct TypeReference : Type | |
433 { | |
434 TypeReference(Type *t); | |
435 Type *syntaxCopy(); | |
436 d_uns64 size(Loc loc); | |
437 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
438 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
439 Expression *defaultInit(Loc loc); | |
440 int isZeroInit(); | |
441 }; | |
442 | |
443 enum RET | |
444 { | |
445 RETregs = 1, // returned in registers | |
446 RETstack = 2, // returned on stack | |
447 }; | |
448 | |
449 struct TypeFunction : Type | |
450 { | |
451 Arguments *parameters; // function parameters | |
452 int varargs; // 1: T t, ...) style for variable number of arguments | |
453 // 2: T t ...) style for variable number of arguments | |
454 enum LINK linkage; // calling convention | |
455 | |
456 int inuse; | |
457 | |
458 TypeFunction(Arguments *parameters, Type *treturn, int varargs, enum LINK linkage); | |
459 Type *syntaxCopy(); | |
460 Type *semantic(Loc loc, Scope *sc); | |
461 void toDecoBuffer(OutBuffer *buf); | |
462 void toCBuffer(OutBuffer *buf, Identifier *ident, HdrGenState *hgs); | |
463 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
464 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
465 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
466 Type *reliesOnTident(); | |
467 | |
468 int callMatch(Expressions *toargs); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
469 #if IN_DMD |
159 | 470 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
471 #endif |
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
472 |
159 | 473 enum RET retStyle(); |
474 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
475 #if IN_DMD |
159 | 476 unsigned totym(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
477 #elif IN_LLVM |
663
6aaa3d3c1183
First part of rename to LDC.
Christian Kamm <kamm incasoftware de>
parents:
658
diff
changeset
|
478 // LDC |
1051
dc608dc33081
Make IrFuncTy a member of TypeFunction. Reset between modules compiled in the
Christian Kamm <kamm incasoftware de>
parents:
1029
diff
changeset
|
479 IrFuncTy fty; |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
480 #endif |
159 | 481 }; |
482 | |
483 struct TypeDelegate : Type | |
484 { | |
485 TypeDelegate(Type *t); | |
486 Type *syntaxCopy(); | |
487 Type *semantic(Loc loc, Scope *sc); | |
488 d_uns64 size(Loc loc); | |
797
340acf1535d0
Removed KDevelop3 project files, CMake can generate them just fine!
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
758
diff
changeset
|
489 unsigned alignsize(); // added in LDC |
159 | 490 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); |
491 Expression *defaultInit(Loc loc); | |
492 int isZeroInit(); | |
493 int checkBoolean(); | |
494 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
495 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
496 int hasPointers(); | |
497 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
498 #if IN_DMD |
159 | 499 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
500 #endif |
159 | 501 }; |
502 | |
503 struct TypeQualified : Type | |
504 { | |
505 Loc loc; | |
506 Array idents; // array of Identifier's representing ident.ident.ident etc. | |
507 | |
508 TypeQualified(TY ty, Loc loc); | |
509 void syntaxCopyHelper(TypeQualified *t); | |
510 void addIdent(Identifier *ident); | |
511 void toCBuffer2Helper(OutBuffer *buf, HdrGenState *hgs); | |
512 d_uns64 size(Loc loc); | |
513 void resolveHelper(Loc loc, Scope *sc, Dsymbol *s, Dsymbol *scopesym, | |
514 Expression **pe, Type **pt, Dsymbol **ps); | |
515 }; | |
516 | |
517 struct TypeIdentifier : TypeQualified | |
518 { | |
519 Identifier *ident; | |
520 | |
521 TypeIdentifier(Loc loc, Identifier *ident); | |
522 Type *syntaxCopy(); | |
523 //char *toChars(); | |
524 void toDecoBuffer(OutBuffer *buf); | |
525 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
526 void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); | |
527 Dsymbol *toDsymbol(Scope *sc); | |
528 Type *semantic(Loc loc, Scope *sc); | |
529 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
530 Type *reliesOnTident(); | |
531 Expression *toExpression(); | |
532 }; | |
533 | |
534 /* Similar to TypeIdentifier, but with a TemplateInstance as the root | |
535 */ | |
536 struct TypeInstance : TypeQualified | |
537 { | |
538 TemplateInstance *tempinst; | |
539 | |
540 TypeInstance(Loc loc, TemplateInstance *tempinst); | |
541 Type *syntaxCopy(); | |
542 //char *toChars(); | |
543 //void toDecoBuffer(OutBuffer *buf); | |
544 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
545 void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); | |
546 Type *semantic(Loc loc, Scope *sc); | |
875
330f999ade44
Merged DMD 1.038
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
797
diff
changeset
|
547 Dsymbol *toDsymbol(Scope *sc); |
159 | 548 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); |
549 }; | |
550 | |
551 struct TypeTypeof : TypeQualified | |
552 { | |
553 Expression *exp; | |
554 | |
555 TypeTypeof(Loc loc, Expression *exp); | |
556 Type *syntaxCopy(); | |
557 Dsymbol *toDsymbol(Scope *sc); | |
558 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
559 Type *semantic(Loc loc, Scope *sc); | |
560 d_uns64 size(Loc loc); | |
561 }; | |
562 | |
563 struct TypeStruct : Type | |
564 { | |
565 StructDeclaration *sym; | |
566 | |
567 TypeStruct(StructDeclaration *sym); | |
568 d_uns64 size(Loc loc); | |
569 unsigned alignsize(); | |
570 char *toChars(); | |
571 Type *syntaxCopy(); | |
572 Type *semantic(Loc loc, Scope *sc); | |
573 Dsymbol *toDsymbol(Scope *sc); | |
574 void toDecoBuffer(OutBuffer *buf); | |
575 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
576 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
577 unsigned memalign(unsigned salign); | |
578 Expression *defaultInit(Loc loc); | |
579 int isZeroInit(); | |
580 int checkBoolean(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
581 #if IN_DMD |
159 | 582 dt_t **toDt(dt_t **pdt); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
583 #endif |
159 | 584 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); |
585 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
586 int hasPointers(); | |
587 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
588 #if IN_DMD |
159 | 589 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
590 #elif IN_LLVM |
1029
4d366a75d95f
Added hasUnalignedFields helper to check if a type has unaligned fields - as per request from fvbommel. Result is cached in TypeStruct.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
1024
diff
changeset
|
591 // LDC |
4d366a75d95f
Added hasUnalignedFields helper to check if a type has unaligned fields - as per request from fvbommel. Result is cached in TypeStruct.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
1024
diff
changeset
|
592 // cache the hasUnalignedFields check |
4d366a75d95f
Added hasUnalignedFields helper to check if a type has unaligned fields - as per request from fvbommel. Result is cached in TypeStruct.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
1024
diff
changeset
|
593 // 0 = not checked, 1 = aligned, 2 = unaligned |
4d366a75d95f
Added hasUnalignedFields helper to check if a type has unaligned fields - as per request from fvbommel. Result is cached in TypeStruct.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
1024
diff
changeset
|
594 int unaligned; |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
595 #endif |
159 | 596 }; |
597 | |
598 struct TypeEnum : Type | |
599 { | |
600 EnumDeclaration *sym; | |
601 | |
602 TypeEnum(EnumDeclaration *sym); | |
603 d_uns64 size(Loc loc); | |
604 unsigned alignsize(); | |
605 char *toChars(); | |
486
a34078905d01
Added pragma(llvmdc, "string") for misc per-module compiler configuration, currently "string" can only be "verbose" which forces -vv for module it appears in.
Tomas Lindquist Olsen <tomas.l.olsen@gmail.com>
parents:
445
diff
changeset
|
606 Type *syntaxCopy(); |
159 | 607 Type *semantic(Loc loc, Scope *sc); |
608 Dsymbol *toDsymbol(Scope *sc); | |
609 void toDecoBuffer(OutBuffer *buf); | |
610 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
611 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
612 Expression *getProperty(Loc loc, Identifier *ident); | |
613 int isintegral(); | |
614 int isfloating(); | |
615 int isscalar(); | |
616 int isunsigned(); | |
617 MATCH implicitConvTo(Type *to); | |
618 Type *toBasetype(); | |
619 Expression *defaultInit(Loc loc); | |
620 int isZeroInit(); | |
621 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
622 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
623 int hasPointers(); | |
624 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
625 #if IN_DMD |
159 | 626 type *toCtype(); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
627 #endif |
159 | 628 }; |
629 | |
630 struct TypeTypedef : Type | |
631 { | |
632 TypedefDeclaration *sym; | |
633 | |
634 TypeTypedef(TypedefDeclaration *sym); | |
635 Type *syntaxCopy(); | |
636 d_uns64 size(Loc loc); | |
637 unsigned alignsize(); | |
638 char *toChars(); | |
639 Type *semantic(Loc loc, Scope *sc); | |
640 Dsymbol *toDsymbol(Scope *sc); | |
641 void toDecoBuffer(OutBuffer *buf); | |
642 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
643 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
644 Expression *getProperty(Loc loc, Identifier *ident); | |
645 int isbit(); | |
646 int isintegral(); | |
647 int isfloating(); | |
648 int isreal(); | |
649 int isimaginary(); | |
650 int iscomplex(); | |
651 int isscalar(); | |
652 int isunsigned(); | |
653 int checkBoolean(); | |
654 Type *toBasetype(); | |
655 MATCH implicitConvTo(Type *to); | |
656 Expression *defaultInit(Loc loc); | |
657 int isZeroInit(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
658 #if IN_DMD |
159 | 659 dt_t **toDt(dt_t **pdt); |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
660 #endif |
159 | 661 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); |
662 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
663 int hasPointers(); | |
664 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
665 #if IN_DMD |
159 | 666 type *toCtype(); |
667 type *toCParamtype(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
668 #endif |
159 | 669 }; |
670 | |
671 struct TypeClass : Type | |
672 { | |
673 ClassDeclaration *sym; | |
674 | |
675 TypeClass(ClassDeclaration *sym); | |
676 d_uns64 size(Loc loc); | |
677 char *toChars(); | |
678 Type *syntaxCopy(); | |
679 Type *semantic(Loc loc, Scope *sc); | |
680 Dsymbol *toDsymbol(Scope *sc); | |
681 void toDecoBuffer(OutBuffer *buf); | |
682 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
683 Expression *dotExp(Scope *sc, Expression *e, Identifier *ident); | |
684 ClassDeclaration *isClassHandle(); | |
685 int isBaseOf(Type *t, int *poffset); | |
686 MATCH implicitConvTo(Type *to); | |
687 Expression *defaultInit(Loc loc); | |
688 int isZeroInit(); | |
689 MATCH deduceType(Scope *sc, Type *tparam, TemplateParameters *parameters, Objects *dedtypes); | |
690 int isauto(); | |
691 int checkBoolean(); | |
692 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
693 int hasPointers(); | |
694 | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
695 #if IN_DMD |
159 | 696 type *toCtype(); |
697 | |
698 Symbol *toSymbol(); | |
1146
1860414bf3b7
* Moved ir/irsymbol.cpp/h into ir/irdsymbol.cpp/h.
Tomas Lindquist Olsen <tomas.l.olsen gmail.com>
parents:
1103
diff
changeset
|
699 #endif |
159 | 700 }; |
701 | |
702 struct TypeTuple : Type | |
703 { | |
704 Arguments *arguments; // types making up the tuple | |
705 | |
706 TypeTuple(Arguments *arguments); | |
707 TypeTuple(Expressions *exps); | |
708 Type *syntaxCopy(); | |
709 Type *semantic(Loc loc, Scope *sc); | |
710 int equals(Object *o); | |
711 Type *reliesOnTident(); | |
712 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
713 void toDecoBuffer(OutBuffer *buf); | |
714 Expression *getProperty(Loc loc, Identifier *ident); | |
715 TypeInfoDeclaration *getTypeInfoDeclaration(); | |
716 }; | |
717 | |
718 struct TypeSlice : Type | |
719 { | |
720 Expression *lwr; | |
721 Expression *upr; | |
722 | |
723 TypeSlice(Type *next, Expression *lwr, Expression *upr); | |
724 Type *syntaxCopy(); | |
725 Type *semantic(Loc loc, Scope *sc); | |
726 void resolve(Loc loc, Scope *sc, Expression **pe, Type **pt, Dsymbol **ps); | |
727 void toCBuffer2(OutBuffer *buf, HdrGenState *hgs, int mod); | |
728 }; | |
729 | |
730 /**************************************************************/ | |
731 | |
732 //enum InOut { None, In, Out, InOut, Lazy }; | |
733 | |
734 struct Argument : Object | |
735 { | |
736 //enum InOut inout; | |
737 unsigned storageClass; | |
738 Type *type; | |
739 Identifier *ident; | |
740 Expression *defaultArg; | |
741 | |
742 Argument(unsigned storageClass, Type *type, Identifier *ident, Expression *defaultArg); | |
743 Argument *syntaxCopy(); | |
744 Type *isLazyArray(); | |
745 void toDecoBuffer(OutBuffer *buf); | |
746 static Arguments *arraySyntaxCopy(Arguments *args); | |
747 static char *argsTypesToChars(Arguments *args, int varargs); | |
748 static void argsToCBuffer(OutBuffer *buf, HdrGenState *hgs, Arguments *arguments, int varargs); | |
749 static void argsToDecoBuffer(OutBuffer *buf, Arguments *arguments); | |
750 static size_t dim(Arguments *arguments); | |
751 static Argument *getNth(Arguments *arguments, size_t nth, size_t *pn = NULL); | |
752 }; | |
753 | |
754 extern int PTRSIZE; | |
755 extern int REALSIZE; | |
756 extern int REALPAD; | |
757 extern int Tsize_t; | |
758 extern int Tptrdiff_t; | |
759 | |
760 #endif /* DMD_MTYPE_H */ |