Mercurial > projects > ldc
comparison gen/tocsym.cpp @ 86:fd32135dca3e trunk
[svn r90] Major updates to the gen directory. Redesigned the 'elem' struct. Much more... !!!
Lots of bugfixes.
Added support for special foreach on strings.
Added std.array, std.utf, std.ctype and std.uni to phobos.
Changed all the .c files in the gen dir to .cpp (it *is* C++ after all)
author | lindquist |
---|---|
date | Sat, 03 Nov 2007 14:44:58 +0100 |
parents | gen/tocsym.c@c53b6e3fe49a |
children | ce7ed8f59b99 |
comparison
equal
deleted
inserted
replaced
85:f869c636a113 | 86:fd32135dca3e |
---|---|
1 | |
2 // Copyright (c) 1999-2005 by Digital Mars | |
3 // All Rights Reserved | |
4 // written by Walter Bright | |
5 // www.digitalmars.com | |
6 // License for redistribution is by either the Artistic License | |
7 // in artistic.txt, or the GNU General Public License in gnu.txt. | |
8 // See the included readme.txt for details. | |
9 | |
10 // stubbed out for dmdfe. Original is in dmd/tocsym.c | |
11 | |
12 #include <stddef.h> | |
13 | |
14 #include "mars.h" | |
15 #include "module.h" | |
16 #include "mtype.h" | |
17 #include "declaration.h" | |
18 #include "statement.h" | |
19 #include "enum.h" | |
20 #include "aggregate.h" | |
21 #include "init.h" | |
22 #include "attrib.h" | |
23 #include "lexer.h" | |
24 #include "symbol.h" | |
25 | |
26 /********************************* SymbolDeclaration ****************************/ | |
27 | |
28 SymbolDeclaration::SymbolDeclaration(Loc loc, Symbol *s, StructDeclaration *dsym) | |
29 : Declaration(new Identifier("", TOKidentifier)) | |
30 { | |
31 } | |
32 | |
33 Symbol *SymbolDeclaration::toSymbol() | |
34 { | |
35 return sym; | |
36 } | |
37 | |
38 /************************************* | |
39 * Helper | |
40 */ | |
41 | |
42 Symbol *Dsymbol::toSymbolX(const char *prefix, int sclass, TYPE *t, const char *suffix) | |
43 { | |
44 return 0; | |
45 } | |
46 | |
47 /************************************* | |
48 */ | |
49 | |
50 Symbol *Dsymbol::toSymbol() | |
51 { | |
52 return 0; | |
53 } | |
54 | |
55 /********************************* | |
56 * Generate import symbol from symbol. | |
57 */ | |
58 | |
59 Symbol *Dsymbol::toImport() | |
60 { | |
61 return 0; | |
62 } | |
63 | |
64 /************************************* | |
65 */ | |
66 | |
67 Symbol *Dsymbol::toImport(Symbol *sym) | |
68 { | |
69 return 0; | |
70 } | |
71 | |
72 /************************************* | |
73 */ | |
74 | |
75 Symbol *VarDeclaration::toSymbol() | |
76 { | |
77 return 0; | |
78 } | |
79 | |
80 /************************************* | |
81 */ | |
82 | |
83 Symbol *ClassInfoDeclaration::toSymbol() | |
84 { | |
85 return 0; | |
86 } | |
87 | |
88 /************************************* | |
89 */ | |
90 | |
91 Symbol *ModuleInfoDeclaration::toSymbol() | |
92 { | |
93 return 0; | |
94 } | |
95 | |
96 /************************************* | |
97 */ | |
98 | |
99 Symbol *TypeInfoDeclaration::toSymbol() | |
100 { | |
101 return 0; | |
102 } | |
103 | |
104 /************************************* | |
105 */ | |
106 | |
107 Symbol *FuncDeclaration::toSymbol() | |
108 { | |
109 | |
110 return 0; | |
111 } | |
112 | |
113 /************************************* | |
114 */ | |
115 | |
116 Symbol *FuncDeclaration::toThunkSymbol(int offset) | |
117 { | |
118 return 0; | |
119 } | |
120 | |
121 /************************************* | |
122 */ | |
123 | |
124 Symbol *FuncAliasDeclaration::toSymbol() | |
125 { | |
126 | |
127 return 0; | |
128 } | |
129 | |
130 | |
131 /**************************************** | |
132 * Create a static symbol we can hang DT initializers onto. | |
133 */ | |
134 | |
135 Symbol *static_sym() | |
136 { | |
137 return 0; | |
138 } | |
139 | |
140 /************************************* | |
141 * Create the "ClassInfo" symbol | |
142 */ | |
143 | |
144 Symbol *ClassDeclaration::toSymbol() | |
145 { | |
146 return 0; | |
147 } | |
148 | |
149 /************************************* | |
150 * Create the "InterfaceInfo" symbol | |
151 */ | |
152 | |
153 Symbol *InterfaceDeclaration::toSymbol() | |
154 { | |
155 return 0; | |
156 } | |
157 | |
158 /************************************* | |
159 * Create the "ModuleInfo" symbol | |
160 */ | |
161 | |
162 Symbol *Module::toSymbol() | |
163 { | |
164 return 0; | |
165 } | |
166 | |
167 /************************************* | |
168 * This is accessible via the ClassData, but since it is frequently | |
169 * needed directly (like for rtti comparisons), make it directly accessible. | |
170 */ | |
171 | |
172 Symbol *ClassDeclaration::toVtblSymbol() | |
173 { | |
174 return 0; | |
175 } | |
176 | |
177 /********************************** | |
178 * Create the static initializer for the struct/class. | |
179 */ | |
180 | |
181 Symbol *AggregateDeclaration::toInitializer() | |
182 { | |
183 return 0; | |
184 } | |
185 | |
186 | |
187 /****************************************** | |
188 */ | |
189 | |
190 Symbol *Module::toModuleAssert() | |
191 { | |
192 return 0; | |
193 } | |
194 | |
195 /****************************************** | |
196 */ | |
197 | |
198 Symbol *Module::toModuleArray() | |
199 { | |
200 return 0; | |
201 } | |
202 | |
203 /******************************************** | |
204 * Determine the right symbol to look up | |
205 * an associative array element. | |
206 * Input: | |
207 * flags 0 don't add value signature | |
208 * 1 add value signature | |
209 */ | |
210 | |
211 Symbol *TypeAArray::aaGetSymbol(char *func, int flags) | |
212 { | |
213 return 0; | |
214 } | |
215 |