2003-11-06 Zoltan Varga <vargaz@freemail.hu>
[mono.git] / mcs / class / corlib / System.Reflection.Emit / ChangeLog
1 2003-11-06  Zoltan Varga  <vargaz@freemail.hu>
2
3         * AssemblyBuilder.cs (get_next_table_index): Moved to ModuleBuilder,
4         since table indexes are per-module.
5
6 2003-11-03  Zoltan Varga  <vargaz@freemail.hu>
7
8         * TypeBuilder.cs (DefineDefaultConstructor): Pass an array instead of 
9         null to DefineConstructor, to avoid NullReferenceExceptions in the 
10         binder code.
11
12         * AssemblyBuilder.cs ModuleBuilder.cs ILGenerator.cs: Move getUSIndex 
13         and getToken methods, and the associated icalls to ModuleBuilder, 
14         since tokens are per-module.
15
16         * AssemblyBuilder.cs ModuleBuilder.cs: Partially revert the previous
17         patch, since having the 'is_main' field is useful in the unmanaged 
18         code.
19
20         * AssemblyBuilder.cs ModuleBuilder.cs: Move the metadata creation and
21         file creation logic to ModuleBuilder:Save (), since this needs to be
22         done for every module. Also move the corresponding icalls to 
23         ModuleBuilder.
24
25 2003-11-03  Zoltan Varga  <vargaz@freemail.hu>
26
27         * AssemblyBuilder.cs ModuleBuilder.cs: First steps toward a fix for
28         #48700 (proper module support in Ref.Emit). Remove is_main field from
29         ModuleBuilder and add a mainModule field to AssemblyBuilder instead.
30         This is neccesary, since the main module is determined during the 
31         Save () call: the module with the same file name as the assembly is
32         the main module. Also create a default main module, if one is not
33         existing.
34
35 2003-11-03  Martin Baulig  <martin@ximian.com>
36
37         * OpCodes.cs: Added Ldelem_Any, Stelem_Any and Unbox_Any from .NET 1.2.
38
39 2003-10-18  Sebastien Pouliot  <spouliot@videotron.ca>
40
41         * AssemblyBuilder.cs (SetCustomAttribute): Changed PK extraction to
42         use Mono.Security.StrongName (#49785).
43
44 2003-10-18  Zoltan Varga  <vargaz@freemail.hu>
45
46         * AssemblyBuilder.cs (SetCustomAttribute): Extract the public key from
47         the keyfile.
48
49 2003-10-17  Zoltan Varga  <vargaz@freemail.hu>
50
51         * AssemblyBuilder.cs (SetCustomAttribute): Ignore empty keyfile name.
52         
53         * AssemblyBuilder.cs: Moved loading of the public key file into
54         managed code from reflection.c. 
55
56         * AssemblyBuilder.cs: Set cultureInfo and version from the AssemblyName
57         passed to the constructor.
58
59 2003-10-13  Martin Baulig  <martin@ximian.com>
60
61         * MethodBuilder.cs (MethodBuilder): Added
62         `TypeBuilder.MonoGenericParam[] generic_params' field.
63         (DefineGenericParameter, SetGenericMethodSignature): New public methods.
64
65         * TypeBuilder.cs (DefineGenericMethod): New public method.
66
67 2003-10-13  Zoltan Varga  <vargaz@freemail.hu>
68
69         * OpCode.cs: Fix Value property. Fixes #49328.
70
71 2003-10-03  Zoltan Varga  <vargaz@freemail.hu>
72
73         * TypeBuilder.cs (CreateType): Fire TypeResolve events for unfinished 
74         nested value types. Fixes #47022.
75
76 2003-09-29  Zoltan Varga  <vargaz@freemail.hu>
77
78         * TypeBuilder.cs: Really fix #48695.
79
80 Sat Sep 27 16:17:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
81
82         * ILGenerator.cs: instance fields are loaded from this.
83
84 2003-09-26  Zoltan Varga  <vargaz@freemail.hu>
85
86         * TypeBuilder.cs (DefineDefaultConstructor): Make this work on types
87         without a parent. Fixes #48695.
88
89 2003-09-17  Martin Baulig  <martin@ximian.com>
90
91         * TypeBuilder.cs (TypeBuilder.CreateType): Don't append the type
92         parameters to the type name; ie. use `Stack' instead of `Stack<T>'.
93
94 2003-09-06  Martin Baulig  <martin@ximian.com>
95
96         * TypeBuilder.cs (TypeBuilder.IsUnboundGenericParameter): Implemented.
97
98 2003-09-04  Martin Baulig  <martin@ximian.com>
99
100         * TypeBuilder.cs (TypeBuilder.MonoGenericParam): Make this nested
101         class internal, not protected.
102
103 2003-08-29  Martin Baulig  <martin@ximian.com>
104
105         * TypeBuilder.cs (TypeBuilder.DefineGenericParameter): New public
106         method.  We can now create generic types.
107         (TypeBuilder.GetGenericTypeDefinition): Override this; call the
108         `setup_internal_class' interncall before calling our base impl.
109
110 Sat Aug  2 13:04:55 BST 2003 Malte Hildingson <malte@amy.udd.htu.se>
111
112         * ILGenerator.cs: Emission of doubles now utilise the Double.AssertEndianity
113         icall to assert double word endianity on ARM.
114
115 2003-07-25  Duncan Mak  <duncan@ximian.com>
116
117         * OpCodes.cs (Boxval): Marked with ObsoleteAttribute.
118
119 2003-07-24  Miguel de Icaza  <miguel@ximian.com>
120
121         * TypeBuilder.cs: Added generics stubs.
122
123         * EnumBuilder.cs: Added generics  stubs, changed bracing style for
124         routines.
125
126 2003-07-23  Duncan Mak  <duncan@ximian.com>
127
128         * SignatureHelper.cs: This class does not have the
129         SerializableAttribute.
130
131 2003-07-11  Zoltan Varga  <vargaz@freemail.hu>
132
133         * AssemblyBuilder.cs: Added argument checking to all methods according
134         to the MSDN docs. Also marked DefineUnmanagedResource and its friends
135         as not implemented.
136         * ModuleBuilder.cs: Added new property FileName used by AssemblyBuilder.
137         * ModuleBuilder.cs AssemblyBuilder.cs: Implemented IsTransient ().
138
139 2003-06-15  Zoltan Varga  <vargaz@freemail.hu>
140
141         * EventBuilder.cs: Add argument checking to methods.
142
143 Thu Jun 5 20:18:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
144
145         * AssemblyBuilder.cs: implemented DefineResource ().
146
147 Thu Jun 5 12:36:34 CEST 2003 Paolo Molaro <lupus@ximian.com>
148
149         * OpCode.cs: implemented Equals/GetHashCode.
150
151 Tue Jun 3 11:14:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
152
153         * ILGenerator.cs, OpCode.cs: optimize opcode space usage.
154
155 Tue Jun 3 11:13:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
156
157         * UnmanagedMarshal.cs: add ability to define custom attributes (the MS
158         runtime doesn't support this).
159
160 2003-05-30  Zoltan Varga  <vargaz@freemail.hu>
161
162         * TypeBuilder.cs: Implement DefineTypeInitializer.
163
164 2003-05-21  Zoltan Varga  <vargaz@freemail.hu>
165
166         * ModuleBuilder.cs: 
167         - Implement DefineInitializedData in terms of DefineUninitializedData
168         - Name the types of global fields $ArrayType$<len> to cut back on the
169         number of types created
170         - Add argument checking
171
172 2003-05-19  Zoltan Varga  <vargaz@freemail.hu>
173
174         * AssemblyBuilder.cs: Implement GetDynamicModule. "Implement" various
175         methods not supported under MS.NET.
176
177 2003-05-18  Martin Baulig  <martin@ximian.com>
178
179         * AssemblyBuilder.cs (corlib_void_type): New internal field.
180         (SetCorlibTypeBuilders): Added overloaded version which takes 4
181         arguments to set the `corlib_void_type'.
182
183         * TypeBuilder.cs: Use `pmodule.assemblyb.corlib_void_type' instead
184         of `typeof (void)' to make this work when compiling corlib.
185
186 Thu May 15 19:16:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
187
188         * MethodBuilder.cs: off by one in CreateMethodBody().
189         * TypeBuilder.cs: if the return type for a method is null, use void.
190
191 2003-04-28  Miguel de Icaza  <miguel@ximian.com>
192
193         * MethodBuilder.cs: Mono allows the parameter position to be zero
194         to indicate the "returns:" attribute.
195
196 2003-04-20  Miguel de Icaza  <miguel@ximian.com>
197
198         * ILGenerator.cs (EmitCall): Implement.
199
200         Flag a few unimplemented methods with MonoTODO, make coding style
201         for method definitions Mono consistent.
202
203 2003-04-17  Zoltan Varga  <vargaz@freemail.hu>
204
205         * ILGenerator.cs: Implement EmitWriteLine methods.
206
207         * TypeBuilder.cs (CreateType): Avoid creating a default constructor
208         for the global type.
209
210 2003-04-15  Miguel de Icaza  <miguel@ximian.com>
211
212         * TypeBuilder.cs (DefineDefaultConstructor): Make it generate code
213         by default for a default constructor.  This is what the MS runtime
214         does.  The PythonNet code expected this.
215
216         (TypeBuilder.GetConstructorImpl): Implement this.
217
218         (TypeBuilder.CreateType): If there are no constructors defined, we
219         create one.
220
221 Tue Apr 15 13:50:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
222
223         * ModuleBuilder.cs, TypeBuilder.cs: set nesting_type before
224         calling setup_internal_class ().
225
226 2003-03-27  Zoltan Varga  <vargaz@freemail.hu>
227
228         * AssemblyBuilder.cs: Added 'access' member, which is needed by the
229         runtime.
230
231 2003-03-26  Zoltan Varga  <vargaz@freemail.hu>
232
233         * ILGenerator.cs: Implemented ThrowException.
234
235 2003-03-10  Zoltan Varga  <vargaz@freemail.hu>
236
237         * ILGenerator.cs: Propagate maxstack info along branches.
238
239 2003-03-06  Zoltan Varga  <vargaz@freemail.hu>
240
241         * ILGenerator.cs (Emit): Do not pop the arguments off the stack for
242         ldftn etc. Fixes bug #39196.
243
244 2003-02-28  Zoltan Varga  <vargaz@freemail.hu>
245
246         * ILGenerator.cs (Emit): Add fixup for already created methods and
247         fields. Do not add fixup for types since their table index do not 
248         change any more.
249
250 2003-02-26  Zoltan Varga  <vargaz@freemail.hu>
251
252         * TypeBuilder.cs (DefineInitializedData): Removed unnecessary assignments.
253
254         * ModuleBuilder.cs (DefineInitializedData): Do not call 
255         TypeBuilder::DefineInitializedData since that would mean defining a
256         nested type of the global type, which is wrong. Instead define a
257         new public type as MS does.
258
259         * ModuleBuilder.cs (DefineUninitializedData): Ditto.
260
261 Thu Feb 13 18:40:52 CET 2003 Paolo Molaro <lupus@ximian.com>
262
263         * ModuleBuilder.cs: add the basic initialization call.
264
265 2003-02-13  Zoltan Varga  <vargaz@freemail.hu>
266
267         * AssemblyBuilder.cs: Added basic error checking to some methods
268         according to the MSDN docs.
269
270 2003-02-10  Zoltan Varga  <vargaz@freemail.hu>
271
272         * ConstructorBuilder.cs: 
273         - Added basic error checking to all methods according to the MSDN docs.
274         - modified a lot of methods to throw NotSupportedException, to comply
275           with MS.NET.
276
277 2003-02-09  Zoltan Varga  <vargaz@freemail.hu>
278
279         * TypeBuilder.cs:
280         - Added basic error checking to all methods according to the MSDN docs.
281         - fixed AssemblyQualifiedName.
282         - implemented 'Size'.
283         - modified a lot of methods to throw NotSupportedException, to comply
284           with MS.NET.
285         - changes tested by running a full bootstrap.
286
287 2003-02-09  Martin Baulig  <martin@ximian.com>
288
289         * AssemblyBuilder.cs (AssemblyBuilder.methods): Removed.  This was
290         a hack for the symbol writer which is no longer needed.
291
292 2003-02-09  Martin Baulig  <martin@ximian.com>
293
294         * IMonoSymbolWriter.cs (DefineNamespace, OpenMethod): New methods.
295
296 2003-02-09  Martin Baulig  <martin@ximian.com>
297
298         * IMonoSymbolWriter.cs (MarkSequencePoint): New method which takes
299         just the required arguments as scalars, not arrays.
300
301         * ILGenerator.cs (ILGenerator.MarkSequencePoint): Use that new
302         interface method; unnecessarily creating such a large number of
303         arrays is both slow and too memory consuming.   
304
305 2003-02-08  Zoltan Varga  <vargaz@freemail.hu>
306
307         * MethodBuilder.cs: Added error checking to methods so they conform to
308         MSDN docs. Implemented 'GetModule' and 'CallingConvention' members. 
309         Some other tweaks to improve compatibility with MS .NET.
310
311         * TypeBuilder.cs: Added 'is_created' property which will be used for
312         checking 'type is already created' errors.
313
314 2003-02-07  Martin Baulig  <martin@ximian.com>
315
316         * ModuleBuilder.cs (.ctor): Added `bool IsMainModule' argument.
317         (Save): New internal method; creates the module's symbol file if
318         we're compiling with debugging information.
319
320         * AssemblyBuilder.cs (EmbedResource): Added internal overloaded
321         version of this method which takes a `byte[] blob' instead of a file.
322         (DefineDynamicMethod): If this is the first module, tell the
323         ModuleBuilder that this is the main module.
324         (Save): Call a new interncall `build_metadata' to create the final
325         metadata and save all the symbol files before creating the actual
326         output.
327
328         * IMonoSymbolWriter.cs: New public class; it is in the namespace
329         Mono.CSharp.Debugger.  The Mono symbol writer implements this interface.
330
331 2003-02-04  Zoltan Varga  <vargaz@freemail.hu>
332
333         * AssemblyBuilder.cs: added GetToken (SignatureHelper).
334
335         * ILGenerator.cs: implemented EmitCalli() methods
336
337         * SignatureHelper.cs: implemented GetMethoSigHelper() methods.
338
339 2003-01-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
340
341         * MethodBuilder.cs: GetBaseDefinition () returns this.
342
343 Mon Jan 27 17:07:38 CET 2003 Paolo Molaro <lupus@ximian.com>
344
345         * CustomAttributeBuilder.cs, FieldBuilder.cs: applied
346         (reformatted) patch from "Jerome Laban" <jlaban@wanadoo.fr>
347         to fix ByValStr and ByValArray encodings.
348
349 2003-01-27  Gonzalo Paniagua Javier <gonzalo@ximian.com>
350
351         * AssemblyBuilder.cs: fixed compilation with csc.
352
353 2003-01-26  Miguel de Icaza  <miguel@ximian.com>
354
355         * AssemblyBuilder.cs (Save): Set the executable bit at the end.
356         This uses a non-official enumeration value to call SetFileAttributes.
357
358 2003-01-17  Zoltan Varga  <vargaz@freemail.hu>
359
360         * MethodBuilder.cs ConstructorBuilder.cs: modify GetParameters() so it
361         returns information even when the app did not use DefineParameter() to
362         define the parameters.
363
364         * ConstructorBuilder.cs (ctor): allways define SpecialName attribute
365         for constructors as done by MS.
366
367 Mon Jan 13 11:37:14 CET 2003 Paolo Molaro <lupus@ximian.com>
368
369         * TypeBuilder.cs, ModuleBuilder.cs: better type name cache.
370
371 2003-01-10  Zoltan Varga  <vargaz@freemail.hu>
372
373         * ILGenerator.cs: Implemented EmitWriteLine(string).
374
375         * TypeBuilder.cs (DefineInitializedData): Call DefineNestedType() 
376         instead of DefineType() so the auxiliary types do not pollute the 
377         global namespace. This is consistent with the behaviour of MS .NET.
378
379 Fri Jan 10 16:03:30 CET 2003 Paolo Molaro <lupus@ximian.com>
380
381         * ILGenerator.cs, MethodBuilder.cs, TypeBuilder.cs,
382         ConstructorBuilder.cs: some tweaks to reduce memory usage.
383
384 Thu Jan 2 18:46:09 CET 2003 Paolo Molaro <lupus@ximian.com>
385
386         * ModuleBuilder.cs, TypeBuilder.cs: support global fields and methods.
387
388 Thu Dec 19 00:06:57 CET 2002 Paolo Molaro <lupus@ximian.com>
389
390         * AssemblyBuilder.cs: remove duplicated user string entries.
391
392 2002-12-11  Zoltan Varga  <vargaz@freemail.hu>
393
394         * FieldBuilder.cs: added 'handle' field which is needed by some new
395         code in reflection.c.
396
397 2002-12-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
398
399         * TypeBuilder.cs: implemented GetInterfaceMap () when the Type has been
400         created.
401
402 Fri Nov 8 14:53:03 CET 2002 Paolo Molaro <lupus@ximian.com>
403
404         * ILGenerator.cs: account for the exception object being passed to the
405         catch handler to calc max_stack.
406
407 2002-09-21  Martin Baulig  <martin@gnome.org>
408
409         * ModuleBuilder.cs (ModuleBuilder.symbol_writer): Make this
410         field internal, not private.
411         (ModuleBuilder.SymWriter_DefineLocalVariable): Removed.
412
413         * LocalBuilder.cs (LocalBuilder.SetLocalSymInfo): Use the
414         ISymbolWriter's DefineLocalVariable() method instead of the
415         IMonoSymbolWriter hack.
416
417 Mon Sep 16 19:02:58 CEST 2002 Paolo Molaro <lupus@ximian.com>
418
419         * AssemblyBuilder.c: special case some custom attributes.
420
421 2002-09-12  Dick Porter  <dick@ximian.com>
422
423         * TypeBuilder.cs: Say _which_ Type has already been created
424
425 2002-09-11  Miguel de Icaza  <miguel@ximian.com>
426
427         * ModuleBuilder.cs (GetTypes): Implement.
428
429 Tue Sep 10 12:12:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
430
431         * ConstructorBuilder.cs: added a field to hold the handle.
432
433 Mon Sep 9 17:31:12 CEST 2002 Paolo Molaro <lupus@ximian.com>
434
435         * TypeBuilder.cs: prepare for the real CreateType implementation.
436
437 Tue Aug 27 16:57:18 CEST 2002 Paolo Molaro <lupus@ximian.com>
438
439         * TypeBuilder.cs: remove duplicate code and fix
440         named field reading in custom attr.
441
442 2002-08-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
443
444         * TypeBuilder.cs: UnspecifiedTypeSize is 0.
445
446 Wed Aug 14 17:38:41 CEST 2002 Paolo Molaro <lupus@ximian.com>
447
448         * TypeBuilder.cs: ReflectedType and CreateType fixes.
449
450 Thu Aug 8 10:25:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
451
452         * AssemblyBuilder.cs: added API to embed managed resources.
453
454 2002-08-03  Martin Baulig  <martin@gnome.org>
455
456         * TypeBuilder.cs (TypeBuilder.DeclaringType): Implemented.
457
458 Thu Jul 25 13:57:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
459
460         * AssemblyBuilder.cs: support linking external resources.
461
462 2002-07-19  Martin Baulig  <martin@gnome.org>
463
464         * ILGenerator.cs (Emit (OpCode, LocalBuilder)): Throw an exception
465         when trying to emit a local that was defined in a different ILGenerator.
466
467         * LocalBuilder.cs (LocalBuilder): Added `ILGenetator' argument to
468         the constructor.
469
470 Tue Jul 16 19:32:08 CEST 2002 Paolo Molaro <lupus@ximian.com>
471
472         * ILGenerator.cs: stack size check fix.
473
474 Sat Jul 13 17:30:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
475
476         * AssemblyBuilder.cs: add also the enum_type for compiling corlib.
477         * TypeBuilder.cs: complete IsValueType.
478
479 Sat Jul 13 15:08:12 CEST 2002 Paolo Molaro <lupus@ximian.com>
480
481         * TypeBuilder.cs: better IsValueType.
482
483 2002-07-13  Gonzalo Paniagua Javier <gonzalo@ximian.com>
484
485         * CustomAttributeBuilder.cs: removed compile warning.
486
487 Fri Jul 12 11:34:58 CEST 2002 Paolo Molaro <lupus@ximian.com>
488
489         * ILGenerator.cs: fixup typebuilder tokens as well.
490
491 Tue Jul 9 19:03:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
492
493         * TypeBuilder.cs: special case SerializarionAttribute.
494         Tweaks to get correct code in corlib.
495
496 2002-07-06  Miguel de Icaza  <miguel@ximian.com>
497
498         * ILGenerator.cs (ILGenerator.Emit): For doubles and floats, swap
499         the bytes on big endian systems. 
500
501 2002-07-03  Martin Baulig  <martin@gnome.org>
502
503         * AssemblyBuilder.cs (corlib_object_type, corlib_value_type): Moved
504         these fields up after the last entry in MonoReflectionAssemblyBuilder
505         in reflection.h.
506
507         * TypeBuilder.cs (IsValueTypeImpl): Use the AssemblyBuilder's
508         `corlib_value_type' instead of `typeof (System.ValueType)'.
509         (DefineNestedType): Use the AssemblyBuilder's `corlib_object_type'
510         instead of `typeof (object)'.
511
512 2002-07-02  Martin Baulig  <martin@gnome.org>
513
514         * AssemblyBuilder.cs (corlib_object_type, corlib_value_type): New
515         internal fields.  When compiling corlib, they point to the newly
516         created System.Object and System.ValueType types.
517         (SetCorlibTypeBuilders): New public function.  This will be
518         dynamically called from MCS when compiling corlib.
519
520         * TypeBuilder.cs (DefineInitializedData): Use the AssemblyBuilder's
521         `corlib_value_type' as parent type instead of `typeof (System.ValueType)'
522         to make it work when compiling corlib.
523
524         * ModuleBuilder.cs (assemblyb): Made this field internal, not private.
525
526 Tue Jul 2 18:34:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
527
528         * TypeBuilder.cs: implemented AssemblyQualifiedName.
529         * MethodBuilder.cs, ConstructorBuilder.cs: special case custom attr.
530
531 Mon Jul 1 16:17:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
532
533         * TypeBuilder.cs: implemented AddInterfaceImplementation().
534
535 2002-06-28  Martin Baulig  <martin@gnome.org>
536
537         * MethodBuilder.cs (GetParameters): Return all parameters, not all
538         but the last one.
539
540 2002-06-27  Martin Baulig  <martin@gnome.org>
541
542         * ConstructorBuilder.cs (GetParameters): Implemented.
543
544 Mon Jun 17 14:55:43 CEST 2002 Paolo Molaro <lupus@ximian.com>
545
546         * ModuleBuilder.cs, TypeBuilder.cs: fixes for nested types handling.
547
548 Fri Jun 14 16:21:54 CEST 2002 Paolo Molaro <lupus@ximian.com>
549
550         * CustomAttributeBuilder.cs: added custom attribute related internal
551         helper methods.
552         * FieldBuilder.cs, ParameterBuilder.cs: handle MarshalAs attribute.
553         * UnmanagedMarshal.cs: implemented.
554
555 Mon Jun 10 18:58:18 CEST 2002 Paolo Molaro <lupus@ximian.com>
556
557         * PropertyBuilder.cs: implemented ReflectedType and DeclaringType
558         properties.
559
560 2002-06-07  Martin Baulig  <martin@gnome.org>
561
562         * TypeBuilder.cs (TypeBuilder): Added `PackingSize packing_size' and
563         `int type_size' fields to the constructor.
564         (DefineNestedType): Pass packing_size and type_size to the constructor.
565
566         * ModuleBuilder.cs (DefineType): Pass the packing_size and type_size
567         fields to the TypeBuilder's constructor.
568
569 2002-06-07  Martin Baulig  <martin@gnome.org>
570
571         * TypeBuilder.cs (DefineNestedType): There is no overload for this
572         method which takes 5 args in the specs, removed it.
573
574 Fri Jun 7 17:04:06 CEST 2002 Paolo Molaro <lupus@ximian.com>
575
576         * AssemblyBuilder.cs: updates for PE/COFF rewrite.
577
578 2002-05-30  Martin Baulig  <martin@gnome.org>
579
580         * AssemblyBuilder.cs (methods): Made this internal and don't
581         initialize it.  It will be initialized by the ModuleBuilder's
582         GetSymbolWriter() method.
583         (get_next_table_index): Only store the method in the `methods'
584         array if it's not null.
585
586         * ModuleBuilder.cs (GetSymbolWriter): Initialize the AssemblyBuilder's
587         `methods' field if necessary and pass it as third argument to the
588         symbol writer's constructor.
589
590 2002-05-25  Martin Baulig  <martin@gnome.org>
591
592         * TypeBuilder.cs (TypeToken): Implemented.
593
594 2002-05-24  Martin Baulig  <martin@gnome.org>
595
596         * ModuleBuilder.cs (symwriter_define_local): New private variable.
597         (GetSymbolWriter): Look for a custom version of "DefineLocalVariable"
598         and store it in `symwriter_define_local'.
599         (SymWriter_DefineLocalVariable): New internal method to call the
600         symbol writer's custom DefineLocalVariable() method.  It is safe to
601         call this method if there's no symbol writer.
602
603         * LocalBuilder.cs (SetLocalSymInfo): Use the MethodBuilder'snew
604         SymWriter_DefineLocalVariable().
605
606         * MethodBuilder.cs (GetParameters): Implemented.
607
608 2002-05-22  Martin Baulig  <martin@gnome.org>
609
610         * ModuleBuilder.cs (GetSymbolWriter): Pass the this pointer to the
611         symbol writer's constructor.
612
613 2002-05-22  Martin Baulig  <martin@gnome.org>
614
615         * AssemblyBuilder.cs (methods): New field.
616         (get_next_table_index): Record all methods and constructors
617         (table 0x06) in the `methods' array.  This is read by the
618         Mono.CSharp.Debugger.MonoSymbolWriter::get_method interncall to
619         get the MethodBuilder / ConstructorBuilder back from the token.
620
621         * *Builder.cs (get_next_table_index): Added `object obj' argument.
622         (<constructors>): pass the this pointer to get_next_table_index ().
623
624 2002-05-20  Martin Baulig  <martin@gnome.org>
625
626         * TypeBuilder.cs (DefineField): Call the new `create_internal_class'
627         interncall after adding the first field.  This is used when creating
628         enum types to set `klass->enum_basetype'.
629
630 Thu May 16 16:09:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
631
632         * TypeBuilder.cs: complete special acse support for CharSet, Size and
633         Pack named args in StructLayout attribute.
634
635 Tue May 14 17:13:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
636
637         * MethodBuilder.cs: revert change in accessibility of
638         GetILGenerator(int).
639
640 Tue May 14 13:31:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
641
642         * FieldBuilder.cs, ParameterBuilder.cs: more special-casing of
643         attributes.
644
645 Fri May 10 20:57:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
646
647         * CustomAttributeBuilder.cs: expose internal data for use in
648         reflection.
649         * FieldBuilder.cs, TypeBuilder.cs: special case FieldOffset and
650         StructLayout attributes.
651
652 Fri May 10 16:30:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
653
654         * MethodBuilder.cs, ConstructorBuilder.cs: implemented InitLocals
655         property.
656
657 2002-04-26  Martin Baulig  <martin@gnome.org>
658
659         * ModuleBuilder.cs (DefineDocument): Implemented.
660
661 Tue Apr 16 13:02:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
662
663         * AssemblyBuilder.cs: pad output file to file alignment.
664         * FieldBuilder.cs: ReflectedType.
665         * ModuleBuilder.cs: added guid generation and array method creation.
666         * MonoArrayMethod.cs: array method support code.
667         
668 Wed Apr 10 12:57:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
669
670         * ILGenerator.cs: use a stack to keep track of exception blocks.
671
672 Mon Apr  8 06:19:01  2002 Piers Haken <piersh@friskit.com>
673
674         * ILGenerator.cs: added LabelField.label_base to allow for
675         arbitrary offsets (for switch statement)
676
677 Fri Apr 5 15:41:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
678
679         * AssemblyBuilder.cs: simpler protocol wih the runtime to
680         get the assembly data.
681
682 Tue Mar 26 20:10:24 CET 2002 Paolo Molaro <lupus@ximian.com>
683
684         * AssemblyBuilder.cs: use FileMode.Create.
685         * ILGenerator.cs: optimize localbuilder related opcodes.
686         Track parameters to adjust maxstack.
687         * LocalBuilder.cS: use unsigned for position.
688
689 2002-03-23  Miguel de Icaza  <miguel@ximian.com>
690
691         * LocalBuilder.cs: Drop the symbol_writer as LocalBuilder fields.
692         Do this lazily in SetLocalSymInfo.
693         
694 2002-03-24  Martin Baulig  <martin@gnome.org>
695
696         * ModuleBuilder.cs (GetSymbolWriter): The MonoSymbolWriter's constructor
697         now takes a `string assembly_filename' argument, pass it our fully
698         qualified assembly name.
699
700 2002-03-24  Nick Drochak  <ndrochak@gol.com>
701
702         * ILGenerator.cs: Use #if-#endif instead of if(false){} to disable
703         code.  This way there is no compiler warning.
704
705         * TypeBuilder.cs: Removed the returns that came after the throws.
706         This removes a few more compiler warnings. Also marked with MonoTODO
707         all places where we throw NotImplemented exceptions.
708
709 2002-03-23  Martin Baulig  <martin@gnome.org>
710
711         * SignatureHelper.cs (GetFieldSignatureHelper, GetLocalSignatureHelper):
712         Implemented.
713
714         * LocalBuilder.cs (LocalBuilder): This internal constructor now takes
715         a ModuleBuilder argument instead of a ISymbolWriter one.
716         (SetLocalSymInfo): Create and pass type signature to DefineLocalVariable.
717
718 2002-03-23  Martin Baulig  <martin@gnome.org>
719
720         * ILGenerator.cs (BeginScope, EndScope): Implemented.
721
722 2002-03-20  Martin Baulig  <martin@gnome.org>
723
724         * ModuleBuilder.cs (GetSymbolWriter): New internal function. Dynamically
725         loads the default symbol writer, catch all possible exceptions and return
726         null on failure.
727         (ModuleBuilder): Added `bool emitSymbolInfo' argument to this internal
728         constructor; if set, call GetSymbolWriter ().
729         (GetSymWriter): Implemented.
730
731         * LocalBuilder.cs (LocalBuilder): Added ISymbolWriter argument to this
732         internal method.
733         (SetLocalSymInfo): Implemented, call ISymbolWriter.DefineLocalVariable ()
734         if the symbol writer is not null.
735
736         * ILGenerator.cs (ILGenerator): Call ModuleBuilder.GetSymWriter () to get
737         and store the symbol writer.
738         (DeclareLocal): Pass the symbol writer to LocalBuilder's constructor.
739         (MarkSequencePoint): Implemented, call ISymbolWriter.DefineSequencePoints ()
740         if the symbol writer is not null.
741
742         * AssemblyBuilder.cs (DefineDynamicModule): Pass the `bool emitSymbolInfo'
743         to ModuleBuilder's constructor.
744
745 Sat Mar 16 19:11:47 CET 2002 Paolo Molaro <lupus@ximian.com>
746
747         * ModuleBuilder.cs: handle modified types correctly.
748
749 Thu Mar 7 17:10:42 CET 2002 Paolo Molaro <lupus@ximian.com>
750
751         * AssemblyBuilder.cs: allow saving bigger assemblies.
752         * ILGenerator.cs: add fixup table for fields and methods, since
753         at the end of the compile they may end up with a different table
754         index.
755         * ModuleBuilder.cs: add cache for type names to speed up the type
756         lookups from the compiler.
757         * TypeBuilder.cs: GetInterfaces () returns only interfaces in the
758         current type, not in parents (the docs are wrong).
759
760 Tue Mar 5 18:09:34 CET 2002 Paolo Molaro <lupus@ximian.com>
761
762         * EventBuilder.cs: implemented.
763         * TypeBuilder.cs: implemented DefineEvent() method and UnderlyingSystemType
764         property.
765
766 Mon Mar 4 20:34:52 CET 2002 Paolo Molaro <lupus@ximian.com>
767
768         * ILGenerator.cs: make enough room in the byte array for string
769         tokens.
770         * TypeBuilder.cs: fixed GetInterfaces().
771
772 Mon Mar 4 11:30:40 CET 2002 Paolo Molaro <lupus@ximian.com>
773
774         * TypeBuilder.cs: implemented GetConstructors(), GetFields(),
775         GetMethods(), GetProperties().
776
777 Thu Feb 28 19:15:10 CET 2002 Paolo Molaro <lupus@ximian.com>
778
779         * AssemblyBuilder.cs: call into the runtime to init some basic
780         assembly stuff. Reserve slot 1 of typedef table for .<Module>.
781         * ModuleBuilder.cs: call into the runtime if we need to create a
782         modief type, such as arrays, byref etc.
783         * TypeBuilder.cs: call into the runtime to create the MonoClass
784         representation for the type. Throw exceptions with not implemented
785         stuff.
786
787 Wed Feb 27 18:48:47 CET 2002 Paolo Molaro <lupus@ximian.com>
788
789         * ILGenerator.cs: fix nested exception blocks.
790
791 Wed Feb 20 22:30:49 CET 2002 Paolo Molaro <lupus@ximian.com>
792
793         * AssemblyBuilder.cs: upped compiled assembly size limit.
794         Implemented SetCustomAttribute () methods.
795         * CustomAttributeBuilder.cs: implemented the needed constructor
796         stuff.
797         * Cosntructorbuilder.cs, EnumBuilder.cs, FieldBuilder.cs,
798         MethodBuilder.cs, ModuleBuilder.cs, ParameterBuilder.cs,
799         PropertyBuilder.cs, TypeBuilder.cs: Implemented SetCustomAttribute () methods.
800
801 Wed Feb 20 14:54:01 CET 2002 Paolo Molaro <lupus@ximian.com>
802
803         * AssemblyBuilder.cs: add SetCustomAttribute () to keep the compiler
804         going.
805
806 Fri Feb 15 18:15:04 CET 2002 Paolo Molaro <lupus@ximian.com>
807
808         * ILGenerator.cs: finally block support and fixes.
809
810 Thu Feb 14 18:55:52 CET 2002 Paolo Molaro <lupus@ximian.com>
811
812         * FieldBuilder.cs: Add SetRVAData().
813         * ILGenerator.cs: speed up code array growth.
814         * TypeBuilder.cs: fix IsValueTypeImpl(). Add class_size member.
815         Implement DefineInitializedData().
816
817 Tue Jan 22 23:01:11 CET 2002 Paolo Molaro <lupus@ximian.com>
818
819         * EnumBuilder.cs, TypeBuilder.cs: updates for changes in Type.cs.
820         * ModuleBuilder.cs: fix lookup of nested types.
821
822 Tue Jan 15 22:46:21 CET 2002 Paolo Molaro <lupus@ximian.com>
823
824         * ILGenerator.cs: implement some of the exception support methods.
825
826 Mon Jan 14 17:07:32 CET 2002 Paolo Molaro <lupus@ximian.com>
827
828         * ModulerBuilder.cs: search also for subtypes in GetTypes().
829         * TypeBuilder.cs: bugfix in FullName. Implemented DefineNestedType().
830
831 Fri Jan 11 19:00:29 CET 2002 Paolo Molaro <lupus@ximian.com>
832
833         * MethodBuilder.cs, ConstructorBuilder.cs: save parameter info.
834
835 Thu Jan 10 21:07:54 CET 2002 Paolo Molaro <lupus@ximian.com>
836
837         * ILGenerator.cs: handle type tokens (used for box opcode).
838
839 Wed Jan 9 19:37:55 CET 2002 Paolo Molaro <lupus@ximian.com>
840
841         * ILGenerator.cs: emit float and doubles.
842         * ModuleBuilder.cs: off-by-one error fix and GetType()
843         implementations.
844         * TypeBuilder.cs: AttributesImpl added.
845         * UnmanagedMarshal.cs: stubbed out class.
846
847 Sat Jan 5 15:59:05 CET 2002 Paolo Molaro <lupus@ximian.com>
848
849         * ILGenerator.cs: fix emission of two-bytes opcodes.
850         Missing slot for locals array. Throw exceptions on unimplemented
851         methods.
852         * OpCode.cs: add a comment: the Value property is useless.
853         * OpCodes.cs: fix name of tail opcode (Tail -> Tailcall).
854
855 2002-01-05  Ravi Pratap  <ravi@ximian.com>
856
857         * ConstructorBuilder.cs : Use the MonoTODO attribute.
858
859         * ILGenerator.cs, Label.cs, MethodBuilder.cs, ModuleBuilder.cs,
860         ParameterBuilder.cs, TypeBuilder.cs : Ditto.
861         
862 Thu Jan 3 23:26:15 CET 2002 Paolo Molaro <lupus@ximian.com>
863
864         * ILGenerator.cs: typo fix.
865
866 Mon Dec 24 17:21:30 CET 2001 Paolo Molaro <lupus@ximian.com>
867
868         * TypeBuilder.cs: added DefineMethodOverride().
869         * MethodBuilder.cs: add override_method member and setter.
870
871 Mon Nov 19 13:58:01 CET 2001 Paolo Molaro <lupus@ximian.com>
872
873         * AssemblyBuilder.cs: add method to register a string in the "#US"
874         stream.
875         * EnumBuilder.cs, SignatureHelper.cs: added stubs.
876         * ILGenerator.cs: more stuff implemented.
877         * LocalBuilder.cs: keep track of local var index.
878
879 Thu Nov 15 18:11:23 CET 2001 Paolo Molaro <lupus@ximian.com>
880
881         * ConstructorBuilder.cs: implement the interesting methods.
882         * ILGenerator.cs: adapt for use with both a MethodBuilder and a
883         ConstructorBuilder.
884         * MethodBuilder.cs: add ImplAttributes.
885         * ParameterBuilder.cs: adapt for ConstructorBuilder.
886         * TypeBuilder.cs: add constructors handling.
887
888 Wed Nov 14 17:01:45 CET 2001 Paolo Molaro <lupus@ximian.com>
889
890         * ConstructorBuilder.cs: added missing stubs and some implementation.
891         * CustomAttributeBuilder.cs: added.
892         * EventBuilder.cs: added.
893         * FieldBuilder.cs: updates.
894         * MethodBuilder.cs: stuff to implement P/Invoke methods.
895         * ModuleBuilder.cs: added GetArrayMethod() stub.
896         * ParameterBuilder.cs, PropertyBuilder.cs: updates.
897         * TypeBuilder.cs: updates and stubs.
898
899 2001-11-10  Sean MacIsaac  <macisaac@ximian.com>
900
901         * TypeBuilder.cs: Added implementation for TypeHandle.
902
903 Tue Nov 6 09:13:45 CET 2001 Paolo Molaro <lupus@ximian.com>
904
905         * AssemblyBuilder.cs: define an internal constructor.
906
907 2001-10-07  Miguel de Icaza  <miguel@ximian.com>
908
909         * AssemblyBuilder.cs: Reformatted.
910
911         Added override keywords to those that needed them.
912
913         Removed methods that we do not override, but just inherit
914
915 Tue Sep 25 16:53:08 CEST 2001 Paolo Molaro <lupus@ximian.com>
916
917         * TypeBuilder.cs, ConstructorBuilder.cs, ModuleBuilder.cs: added.