2002-05-19 Martin Baulig <martin@gnome.org>
[mono.git] / mono / metadata / ChangeLog
1 2002-05-19  Martin Baulig  <martin@gnome.org>
2
3         * unicode.c (ves_icall_iconv_get_bytes): Actually use the `charCount'
4         argument to get the length, don't default to the array length.
5
6 2002-05-18  Miguel de Icaza  <miguel@ximian.com>
7
8         * assembly.c (mono_assembly_setrootdir): New function used to
9         override the MONO_ASSEMBLIES directory.
10
11 Fri May 17 20:39:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
12
13         * icall.c: ValueType_GetHashCode() initialize local var.
14
15 Thu May 16 17:20:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
16
17         * reflection.c: sort custom attributes table.
18
19 Thu May 16 16:08:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
20
21         * reflection.c: support named args in custom attributes (write support).
22
23 Thu May 16 13:04:59 CEST 2002 Paolo Molaro <lupus@ximian.com>
24
25         * reflection.c: fix finally position calculation.
26
27 2002-05-15  Radek Doulik  <rodo@ximian.com>
28
29         * reflection.c: fixed endianess at many places
30
31         * icall.c (ves_icall_InitializeArray): comment out debug msg
32
33 2002-05-15  Dietmar Maurer  <dietmar@ximian.com>
34
35         * object.c (mono_unhandled_exception): new function to handle
36         unhandled exceptions.
37         (mono_unhandled_exception): call the UnhandledException event.
38         (mono_runtime_delegate_invoke): impl.
39
40 Wed May 15 15:59:55 CEST 2002 Paolo Molaro <lupus@ximian.com>
41
42         * metadata.h, metadata.c, class.c: mono_metadata_field_info ()
43         returns the RVA, not the direct pointer to the data. Handle the case
44         when the class size is fixed.
45
46 Tue May 14 16:59:44 CEST 2002 Paolo Molaro <lupus@ximian.com>
47
48         * reflection.c: fix some endianess issues.
49
50 2002-05-14  Dietmar Maurer  <dietmar@ximian.com>
51
52         * object.c (mono_runtime_invoke): is now able to catch exceptions.
53
54         * threads.c (mono_thread_init): added a callback which is invoked
55         at thread start.
56
57 2002-05-14  Dan Lewis  <dihlewis@yahoo.co.uk>
58         
59         * icall.c: make GetHashCode return non-negative values.
60
61 2002-05-14  Dan Lewis  <dihlewis@yahoo.co.uk>
62
63         * object.c, icall.c, gc.c: revert to address-based hashcode.
64
65 2002-05-13  Miguel de Icaza  <miguel@ximian.com>
66
67         * icall.c (mono_double_ParseImpl): Added ParseImpl method.
68
69 Mon May 13 16:40:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
70
71         * icall.c, class.c: special case <Module>.
72
73 2002-05-13  Dan Lewis  <dihlewis@yahoo.co.uk>
74
75         * icall.c: fix bug in GetNow().
76
77 2002-05-11  Dietmar Maurer  <dietmar@ximian.com>
78
79         * object.c (mono_runtime_class_init): make sure that we call all
80         static class constructors.
81
82 Fri May 10 18:14:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
83
84         * reflection.c: sort methodsemantics table.
85
86 Fri May 10 16:31:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
87
88         * reflection.h, reflection.c: honour init locals setting.
89
90 Thu May 9 18:50:00 EDT 2002 Daniel Morgan <danmorg@sc.rr.com>
91
92         * icall.c: copied Double ToStringImpl for Single ToStringImpl
93
94 Wed May 8 12:28:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
95
96         * reflection.c: support ContructorBuilders in attribute blob creation.
97
98 Wed May 8 12:06:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
99
100         * reflection.c: some changes to build a binary that can be run
101         directly in windows.
102
103 Mon May 6 13:10:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
104
105         * loader.c: print a big message when an icall can't be found.
106
107 2002-05-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
108
109         * string-icalls.c: fix bug 24248.
110
111 Sat May 4 14:03:21 CEST 2002 Paolo Molaro <lupus@ximian.com>
112
113         * appdomain.c, appdomain.h, assembly.c, assembly.h, image.h,
114         icall.c, reflection.h: separate assembly loading by pathname and by
115         assembly name. Use the MONO_PATH env var to search for assemblies.
116
117 Thu May 2 17:56:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
118
119         * assembly.c, image.h: add some support for assemblies
120         with multiple modules.
121         * class.c, class.h: export mono_class_from_typeref().
122         * loader.c: remove duplicated code and use mono_class_from_typeref(),
123         instead.
124
125 Thu May 2 15:51:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
126
127         * unicode.c: Char.IsNumber doesn't include hex digits as the ms
128         documentation says (the ECMA one is correct).
129
130 2002-05-02  Dick Porter  <dick@ximian.com>
131
132         * threads.c: Use GC_debug_register_finalizer with GC_debug_malloc.
133         Don't name the synchronisation mutex.
134
135 2002-04-30  Jeffrey Stedfast  <fejj@ximian.com>
136
137         * rand.c
138         (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetBytes):
139         Make the prototypes match.
140         (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetNonZeroBytes):
141         Same.
142
143         * icall.c
144         (ves_icall_System_CurrentTimeZone_GetTimeZoneData): Fixed for
145         systems that use 'timezone' rather than tm.tm_gmtoff. Also, not
146         all systems have tm.tm_zone, so use strftime() with %Z to print
147         the timezone abreviation into a temp string.
148
149         * object.c (mono_ldstr): Fixed to use mono_string_chars() macro
150         rather than mono_array_addr() on a MonoString on Big Endian
151         machines.
152
153 2002-04-30  Dietmar Maurer  <dietmar@ximian.com>
154
155         * string-icalls.c (ves_icall_System_String_InternalReplace_Str):
156         fix bug 24041
157
158 2002-04-30  Dick Porter  <dick@ximian.com>
159
160         * socket-io.c: Cope with SOCKET being an integer rather than a
161         pointer now.
162
163         * threads.c: Added Thread_free_internal, to deal with thread
164         handle cleanup.  Moved calls to handle_store() and handle_remove()
165         to start_wrapper(), so each can only be called once.  Allocate
166         synchronisation blocks with GC_malloc(), and use GC finalisation
167         to close the handles.
168
169         * icall.c: added System.Threading.Thread::Thread_free_internal
170
171 Mon Apr 29 15:33:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
172
173         * icall.c: support Environment.Exit, CommandLineArgs().
174
175 Mon Apr 29 15:15:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
176
177         * object.c, object.h: added mono_runtime_run_main () and
178         mono_runtime_get_main_args () for use in System.Environment.
179
180 Mon Apr 29 13:45:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
181
182         * gc.c: fix thinko, enable actual finalization since the jit is now
183         fixed.
184
185 Mon Apr 29 12:47:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
186
187         * gc.c, object.c: take into account that an object may be offset wrt the address
188         returned by GC_malloc().
189
190 Mon Apr 29 12:14:39 CEST 2002 Paolo Molaro <lupus@ximian.com>
191
192         * image.c: handle files without entries in the assembly table (modules).
193
194 2002-04-28 Patrik Torstensson <patrik.torstensson@intel.com>
195
196         * reflection.c (mono_reflection_setup_internal_class): remove g_assert_not_reached() to allow 
197         mcs selfhosting again (build breaker) and did move the check to class instead. parent is
198         allowed to be null when it's System.Object class setup.
199
200 2002-04-27  Martin Baulig  <martin@gnome.org>
201
202         * reflection.c (mono_reflection_setup_internal_class): g_assert_not_reached()
203         if `tb->parent == NULL' rather than crashing.
204
205 2002-04-28  Nick Drochak  <ndrochak@gol.com>
206
207         * sysmath.c (ves_icall_System_Math_Asin): Fix copy-paste error.  Was
208         calling acos() where asin() should have been called.
209
210 2002-04-26  Martin Baulig  <martin@gnome.org>
211
212         * assembly.c (default_assembly_name_resolver): Use G_FILE_TEST_IS_REGULAR
213         instead of G_FILE_TEST_EXISTS - if you're in mcs/class/corlib/System/Test,
214         there's a subdirectory called `System', but we don't want to read that
215         subdirectory as an assembly.
216
217 2002-04-25  Martin Baulig  <martin@gnome.org>
218
219         * debug-symfile.c: Reflect latest MonoString changes.
220
221 Thu Apr 25 16:38:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
222
223         * rand.c, rand.h: instance method icalls need to have an explicit
224         this pointer as first argument in the C implementation.
225
226 2002-04-25  Nick Drochak <ndrochak@gol.com>
227
228         * icall.c: Fix typo in map for GetNonZeroBytes
229
230 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
231
232         * string-icalls.c : String does now passes unit tests without any 
233         errors, the following changes has been made:
234         
235         Implemented replace methods.
236         Renaming of methods to (try) follow the standard.
237         Fixed compare ordinal
238         Made all memory allocated directly to function instead of via icall function.
239         Small performance fix in is_in_array function
240                         
241  (2002-04-23) Changes from Duncan Mak <duncan@ximian.com>
242
243         c (mono_string_Internal_ctor_charp_int_int):
244         (mono_string_Internal_ctor_sbytep_int_int):  Removed check for
245         sindex < 0, throw ArgumentOutOfRangeException instead of
246         ArgumentNullException.
247
248         Added new check for length == 0, however
249         I need to make it return String.Empty from the C code.
250         
251         (mono_string_Internal_ctor_sbytep): Use mono_string_new, and let
252         that calculate the length for us here.
253         
254         (mono_string_Internal_ctor_sbytep_int_int): Replaced
255         mono_string_new_utf16 with mono_string_new, since value is utf8.
256
257 Wed Apr 24 18:43:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
258
259         * object.c: register the object for finalization if needed.
260         Allocate one more char in the string for the terminating 0 char.
261
262 Wed Apr 24 18:22:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
263
264         * class.c, class.h, image.c: check if a type implemenst a destructor.
265         Use the proper key for array class lookups.
266         * icall.c: register the icalls in the System.GC class.
267         * gc.c, gc.h: GC-related functions and icalls.
268
269 2002-04-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
270
271         * icall.c:
272         * socket-io.c:
273         * unicode.c: free some strings gotten from mono_string_to_utf8 and
274         changed a couple of free () by g_free ().
275
276         * decimal.c: one-liner in the comments for decimal2string ().
277
278 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
279
280         * object.c (mono_runtime_invoke_array) : Bug because of my incompetence.
281
282 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
283
284         * reflection.c (mono_reflection_get_custom_attrs) : fixed image bug (crash)
285         * object.c (mono_runtime_invoke_array) : handle null in params
286
287 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
288
289         * string-icalls.c: fixed bug in split (one off bug)
290
291 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
292
293         * string-icalls.c: fixed bug in remove and lastindexofany, add equals icall.
294         * icalls.c: added String::Equals as internal method
295
296 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
297
298         * threads.c: fixed bug in the double interlocked functions
299
300 2002-04-22      Patrik Torstensson <patrik.torstensson@labs2.com>
301
302         * threads.c: implemented all of the new interlocked icalls.
303         * string-icalls.c: fix a bug in insert.
304         * icalls.c: added the icalls for interlocked, removed old string functions.
305         
306 Mon Apr 22 19:44:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
307
308         * loader.c: fix off-by-one error when reading argument names.
309
310 Mon Apr 22 19:28:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
311
312         * profiler.c: win32 counter implementation (untested).
313         * icall.cs: win32 GetNow() and GetTimeZoneData() implementations
314         (the latter needs testing and more complete impl. from win32 folks).
315
316 2002-04-21  Dan Lewis  <dihlewis@yahoo.co.uk>
317
318         * object.c: mono_array_new_full workaround mono_array_class_get
319         problem.
320
321 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
322
323         * string-icalls.c (mono_string_InternalRemove): Fixed overwrite bug.
324         * object.h (mono_string_chars): Changed casting type.
325
326 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
327
328         * string-icalls.c: Fixed trim method, added the constructors done by Duncan, fixed
329                            method signatures to use gunichar2 instead of gint16.
330
331 2002-04-20  Dan Lewis  <dihlewis@yahoo.co.uk>
332
333         * object.h, object.c: domain-specific versions of mono_object_new and
334         mono_array_new.
335
336 2002-04-20  Dietmar Maurer  <dietmar@ximian.com>
337
338         * object.c: changed String layout
339
340         * string-icalls.c (mono_string_Internal_ctor_chara): added
341         internal string constructors.
342
343 Sat Apr 20 13:33:07 CEST 2002 Paolo Molaro <lupus@ximian.com>
344
345         * threads.c: pass 'this' to the thread start routine.
346
347 2002-04-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
348
349         * string-icalls.c: fix IndexOf and LastIndexOf. Now
350         InternalCompareStr don't call twice mono_string_cmp_char for the last
351         character. Improved performance in mono_string_cmp_char.
352
353 Fri Apr 19 19:26:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
354
355         * Makefile.am, appdomain.c, class.c, object.c: split runtime-depended
356         code into its own library: libmonoruntime.
357
358 2002-04-19  Dan Lewis  <dihlewis@yahoo.co.uk>
359
360         * object.h, object.c: changed array format so that szarrays do not
361         require a bounds structure.
362         * icall.c, appdomain.c: support for new szarray format.
363
364 Fri Apr 19 18:04:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
365
366         * metadata.c: compare also the retuns type when comparing signatures:
367         we didn't do this as an optimization since really overloaded methods
368         must differ also in the arguments, but this doesn't work with
369         low-level IL code (or when using explicit conversion operators: see
370         bug#23498 for an example).
371
372 Fri Apr 19 16:14:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
373
374         * loader.c: SZARRAY types can be saved as TYPESPEC, too.
375
376 Thu Apr 18 17:15:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
377
378         * icall.c: make MonoType::GetElementType its own icall.
379
380 Thu Apr 18 16:41:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
381
382         * icall.c: remove MonoMethod_get_Name().
383         * reflection.c, reflection.h, verify: cache the method name in the MonoMethod
384         object.
385
386 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
387
388         * string-icalls.c: optimized a few methods.
389
390 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
391
392         * icall.c: added all new string internal calls
393         * string-icalls.c: added, new string internal call implementation.
394         * object.c: added mono_string_new_size for allocating a string a size
395
396 2002-04-17  Dietmar Maurer  <dietmar@ximian.com>
397
398         * object.c (mono_object_isinst): use the same code as in the
399         optimized x86 version.
400
401 Wed Apr 17 14:14:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
402
403         * profiler.c: TSC-based timer code (faster and more accurate).
404         Not hooked up in configure, yet (set USE_X86TSC to 1).
405
406 Wed Apr 17 12:33:10 CEST 2002 Paolo Molaro <lupus@ximian.com>
407
408         * profiler.c, profiler.h: track time spent compiling methods.
409         * threads.c: track thread creation/destruction.
410
411 Tue Apr 16 20:08:43 CEST 2002 Paolo Molaro <lupus@ximian.com>
412
413         * profiler.c, profiler.h, profiler-private.h: profiling interface
414         and sample implementation. Moved here so that it can be used also by
415         the jit.
416
417 Tue Apr 16 12:58:12 CEST 2002 Paolo Molaro <lupus@ximian.com>
418
419         * reflection.c, reflection.h: keep types and other handles separate in
420         the hash tables for referred tokens. Add guid for modules.
421
422 Mon Apr 15 11:37:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
423
424         * assembly.c: fix bugs found with valgrind.
425         * metadata.h, metadata.c: added mono_metadata_guid_heap().
426
427 2002-04-14      Patrik Torstensson <patrik.torstensson@labs2.com>
428
429         * threads: added icall support for getting current domain for
430                    the thread.
431  
432 2002-04-13  Martin Baulig  <martin@gnome.org>
433
434         * debug-symfile.h (MonoDebugLocalInfo): Renamed to MonoDebugVarInfo.
435         (MonoDebugVarInfo): Added `index' field for register based addresses.
436         (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 9.
437         (MonoDebugMethodInfo): Replaced `guint32 *param_offsets' with
438         `MonoDebugVarInfo *params' and `guint32 this_offset' with
439         `MonoDebugVarInfo *this_var'.
440
441         * debug-symfile.c (relocate_variable): New static function to write
442         a location description for a local variable or method parameter.
443
444 2002-04-12  Martin Baulig  <martin@gnome.org>
445
446         * debug-symfile.h (MonoDebugLocalInfo): New type. This contains the
447         stack offset and begin/end scope address of a local variable.
448         (MonoDebugMethodInfo): Replaced `guint32 *local_offsets' with
449         'MonoDebugLocalInfo *locals', added `prologue_end' and `epilogue_begin'.
450         (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 8.
451
452         * debug-symfile.c (MRT_variable_start_scope, MRT_variable_end_scope):
453         Added new relocation types for start/end scope of a local variable.
454
455 Fri Apr 12 18:30:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
456
457         * object.h: add mono_object_domain() macro.
458         * reflection.c: handle typespecs.
459         * icall.c: MonoMethod::get_Name() implementation.
460
461 Thu Apr 11 12:29Ni:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
462
463         * icall.c: String::GetHashCode() icall implementation.
464
465 Wed Apr 10 21:16:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
466
467         * icall.c: String::IndexOfAny icall.
468         * object.c, object.h: make array->max_length more useful.
469         Intrduced mono_object_class() and mono_string_length() macros.
470
471 2002-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
472
473         * unicode.c (ves_icall_System_Char_IsNumber): use g_unichar_isxdigit
474         instead of g_unichar_isdigit.
475
476 2002-04-11  Nick Drochak  <ndrochak@gol.com>
477
478         * icall.c: Implement a simple Double.ToString().
479
480 Tue Apr 9 21:31:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
481
482         * appdomain.h: only io-layer.h is supposed to be included.
483         * icall.c: explicitly import environ. Fix warning.
484
485 2002-04-10  Nick Drochak  <ndrochak@gol.com>
486
487         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData) :
488                 return true even if it's not Daylight Savings time.
489                 Only return false for the case where the function isn't
490                 implemented for a plaform (read Windows).
491
492 Tue Apr 9 13:05:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
493
494         * appdomain.h, appdomain.c, class.c, object.c: protect MonoDomain
495         data with a mutex.
496
497 2002-04-09  Dietmar Maurer  <dietmar@ximian.com>
498
499         * mempool.c (mono_mempool_alloc): only use g_malloc when
500         absolutely necessary.
501
502 2002-04-08  Dietmar Maurer  <dietmar@ximian.com>
503
504         * mempool.c (MEM_ALIGN): hardcode MEM_ALIGN to 8
505
506         * class.c (mono_class_vtable): use domain mempool to allocate vtable
507         (mono_class_proxy_vtable): use domain mempool
508
509 Mon Apr 8 17:17:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
510
511         * appdomain.h, appdomain.c: split initialization that requires the
512         execution engine support into mono_runtime_init().
513
514 2002-04-08  Dietmar Maurer  <dietmar@ximian.com>
515
516         * class.c (mono_class_init): don't include vtable inside MonoClass
517         to save some memory, gather some statistics.
518         (mono_class_vtable): use g_malloc instead of GC_malloc when possible
519
520 Sat Apr 6 20:07:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
521
522         * icall.c: internalcall implementation for ValueType.Equals().
523
524 2002-04-06  Dietmar Maurer  <dietmar@ximian.com>
525
526         * object.c (mono_message_init): moved 
527         (mono_runtime_exec_main): new arch. independent impl.
528         (mono_runtime_invoke_array): new method - like
529         mono_runtime_invoke, but you can pass an array of objects.
530         (mono_remoting_invoke): new arch. independent impl.
531         (mono_message_invoke): new arch. independent impl.
532         (mono_runtime_class_init): new arch. independent impl.
533         (mono_runtime_object_init): new arch. independent impl.
534
535 Fri Apr 5 18:29:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
536
537         * metadata.c, object.c, reflection.c: documented the exported
538         functions.
539
540 Fri Apr 5 15:42:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
541
542         * icall.c: simpler code to pass the assembly builder data to corlib.
543         Implement GetNestedTypes() internalcall.
544
545 Thu Apr 4 21:46:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
546
547         * class.c: warn if a type can't be loaded.
548
549 2002-04-04  Dietmar Maurer  <dietmar@ximian.com>
550
551         * image.h: typedef MonoImageOpenStatus
552         * types.h: removed unused file
553         
554 2002-04-04  Dan Lewis  <dihlewis@yahoo.co.uk>
555
556         * icall.c: Enum_ToObject accepts enum value arguments.
557
558 Thu Apr 4 11:35:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
559
560         * class.c: move initialization of properties, events and nested
561         classes, so that they happen for interfaces, too.
562
563 Wed Apr 3 20:03:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
564
565         * icall.c: cleanup some ugly casts in Array_SetValue*.
566
567 Wed Apr 3 19:49:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
568
569         * icall.c: the values array fro enums is of the correct type, now.
570         Implement (correctly) getFullName instead of assQualifiedName for
571         MonoType.
572         * reflection.h, reflection.c: added mono_type_get_name ().
573
574 Wed Apr 3 17:56:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
575
576         * assembly.c, image.h: for each MonoImage, record from wich assembly
577         it was loaded.
578         * reflection.h, icall.c: added System_Reflection_Assembly_GetTypes().
579         Make Type.Assembly work.
580
581 2002-04-03  Dietmar Maurer  <dietmar@ximian.com>
582
583         * debug-symfile.h: use char* instead of gpointer to avoid
584         unnecessary casts.
585
586         * appdomain.c (mono_jit_info_table_find): use char* instead of gpointer
587
588         * icall.c (ves_icall_InternalExecute): impl. FielSetter
589         (ves_icall_System_Array_SetValueImpl): removed strange MonoArray cast
590
591 2002-03-30  Dietmar Maurer  <dietmar@ximian.com>
592
593         * icall.c (mono_message_init): impl. (code cleanup)
594         (ves_icall_InternalExecute): impl. FieldGetter
595
596         * class.c (mono_class_init): added exerimental EXT_VTABLE_HACK, if
597         defined we call all (non-static)methods through the vtable. 
598
599 Fri Mar 29 18:09:08 CET 2002 Paolo Molaro <lupus@ximian.com>
600
601         * class.c: it seems GC_debug_malloc() makes the Boehm GC call the
602         finalizer even though the memory is still referenced (and the chunk of
603         memory is not freed).
604
605 Fri Mar 29 17:43:04 CET 2002 Paolo Molaro <lupus@ximian.com>
606
607         * assembly.c: fix brokeness.
608
609 Fri Mar 29 16:09:54 CET 2002 Paolo Molaro <lupus@ximian.com>
610
611         * class.c: kill some warnings. Check explicit interface method
612         implementation also without considering the namespace.
613         Load also literal strings in static class data.
614
615 2002-03-29  Miguel de Icaza  <miguel@ximian.com>
616
617         * assembly.c (default_assembly_name_resolver): Kill memory leak. 
618         (default_assembly_name_resolver): Make the resolver take the
619         "base" directory where the assembly was originally defined, so we
620         can load DLLs that are in the same directory as the assembly that
621         is being referenced.
622
623 2002-03-28  Dick Porter  <dick@ximian.com>
624
625         * file-io.h: 
626         * file-io.c:
627         * socket-io.c: 
628         * unicode.h: 
629         * unicode.c: Warning cleanups
630
631 Thu Mar 28 18:06:14 CET 2002 Paolo Molaro <lupus@ximian.com>
632
633         * object.h, reflection.h: use the correct type instead of MonoObject.
634
635 2002-03-28  Martin Baulig  <martin@gnome.org>
636
637         * debug-symfile.c (mono_debug_class_get): Don't look in referenced assemblies.
638         (mono_debug_update_symbol_file): Initialize classes if necessary.
639
640 Thu Mar 28 15:58:43 CET 2002 Paolo Molaro <lupus@ximian.com>
641
642         * assembly.c, debug-helpers.c, image.c, image.h, metadata.c, pedump.c,
643         rawbuffer.c, reflection.c, verify.c: mare warning cleanups.
644
645 Thu Mar 28 15:20:39 CET 2002 Paolo Molaro <lupus@ximian.com>
646
647         * assembly.h: fix function prototype.
648         * metadata.h, metadata.c, object.h, private.h: get rid of warnings.
649         * mono-endian.h: use const cast.
650
651 2002-03-28  Dietmar Maurer  <dietmar@ximian.com>
652
653         * icall.c (ves_icall_MonoMethodMessage_InitMessage): moved from message.c
654
655 Thu Mar 28 12:32:00 CET 2002 Paolo Molaro <lupus@ximian.com>
656
657         * loader.c: don't assert when a typeref can't be loaded, give
658         a chance to the runtime to trow an exception instead.
659         * loader.h: fix warning.
660
661 2002-03-28  Dietmar Maurer  <dietmar@ximian.com>
662
663         * class.c (mono_class_proxy_vtable): added proxy support
664
665 2002-03-27  Dan Lewis <dihlewis@yahoo.co.uk>
666
667         * icall.c: removed last of PAL calls, added System.Environment
668         * file-io.h, file-io.c: MonoIO implementation
669         * object.h, object.c: mono_string_to_utf16() now returns gunichar2*
670
671 Tue Mar 26 19:56:10 CET 2002 Paolo Molaro <lupus@ximian.com>
672
673         * appdomain.c: do not use the byte marker in ldstr table lookup.
674         * debug-helpers.c: allow two ':' to separate class and method name.
675         * object.c: allocate arrays bounds with the GC, too.
676         * verify: add a few more checks.
677
678 Tue Mar 26 18:45:46 CET 2002 Paolo Molaro <lupus@ximian.com>
679
680         * reflection.c: output also literal strings. Allocate parameter data
681         with GC_malloc() (thanks, Martin, for catching this!).
682
683 2002-03-26  Martin Baulig  <martin@gnome.org>
684
685         * debug-symfile.h (MonoDebugMethodInfo): Added `this_offset', don't
686         include the `this' offset in the `param_offsets'.
687
688 2002-03-25  Martin Baulig  <martin@gnome.org>
689
690         * debug-symfile.c (mono_debug_update_symbol_file): Use a new
691         mono_debug_get_class() function to get the classes. Added new
692         relocation types for arrays and strings.
693         (mono_debug_get_class): New static function to search in all
694         referenced assemblies for a metadata token.
695
696         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 7.
697
698 Mon Mar 25 13:08:18 CET 2002 Paolo Molaro <lupus@ximian.com>
699
700         * reflection.h, reflection.c: use a gc-safe hash for hash tables that
701         hold gc-allocated objects. Make the string heap a stream like the
702         others. Removed duplicated code when writing stream info.
703         Added asserts to catch possible buffer overflows. Set the sorted map
704         for tables that need sorting. Added some documentation.
705
706 Mon Mar 25 13:04:56 CET 2002 Paolo Molaro <lupus@ximian.com>
707
708         * appdomain.h, appdomain.c, class.c, object.c: use a GC-safe hash table 
709         for interned strings and vtables.
710
711 2002-03-24  Martin Baulig  <martin@gnome.org>
712
713         * icall.c (ves_icall_Type_GetFields): Reverse the list before storing
714         it in the array since it was created with g_slist_prepend().
715
716 2002-03-24  Martin Baulig  <martin@gnome.org>
717
718         * debug-symfile.c (mono_debug_local_type_from_signature): Renamed
719         to ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig().
720         (mono_debug_method_from_token): Renamed to
721         ves_icall_Debugger_MonoSymbolWriter_method_from_token().
722         (ves_icall_Debugger_DwarfFileWriter_get_type_token): New interncall.
723
724         * debug-symfile.c (MRT_type_sizeof, MRT_type_field_offset): New
725         relocation types.
726
727         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 6.
728
729 2002-03-24  Martin Baulig  <martin@gnome.org>
730
731         * debug-symfile.c (mono_debug_local_type_from_signature): New func.
732         (mono_debug_method_from_token): New func.
733
734         * icall.c (Mono.CSharp.Debugger.MonoSymbolWriter::get_local_type_from_sig):
735         New interncall, calls mono_debug_local_type_from_signature().
736         (Mono.CSharp.Debugger.MonoSymbolWriter::get_method): New interncall,
737         calls mono_debug_method_from_token().
738
739 2002-03-23  Martin Baulig  <martin@gnome.org>
740
741         * unicode.c (ves_icall_iconv_get_char_count): The `count' argument
742         specifies the number of bytes to be converted, not the array size.
743         Return the number of chars, not the number of bytes.
744         (ves_icall_iconv_get_chars): The `byteCount' argument
745         specifies the number of bytes to be converted, not the array size.
746
747 2002-03-23  Martin Baulig  <martin@gnome.org>
748
749         * reflection.h (MonoReflectionSigHelper): New type.
750
751         * reflection.c (mono_reflection_sighelper_get_signature_local),
752         (mono_reflection_sighelper_get_signature_local): New functions.
753
754         * icall.c (System.Reflection.Emit.SignatureHelper::get_signature_local),
755         (System.Reflection.Emit.SignatureHelper::get_signature_field): New
756         interncalls.
757
758 2002-03-23  Martin Baulig  <martin@gnome.org>
759
760         * rawbuffer.c (mono_raw_buffer_load_mmap): Use MAP_SHARED when
761         is_writeable is set.
762         (mono_raw_buffer_update): New function to write the modified map
763         back to disk.
764
765         * debug-symfile.h (MonoDebugSymbolFile): Added `raw_contents_size'.
766
767         * debug-symfile.c (mono_debug_update_symbol_file): Call
768         mono_raw_buffer_update() when done writing.
769
770 2002-03-23  Martin Baulig  <martin@gnome.org>
771
772         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 5.
773
774         * debug-symfile.c: Added support for arguments and local variables.
775
776 2002-03-23  Dick Porter  <dick@ximian.com>
777
778         * debug-symfile.c: Remove extraneous 'include <elf.h>' that wasn't
779         protected by ifdefs, hence breaking the w32 build.
780
781 Thu Mar 21 17:35:01 CET 2002 Paolo Molaro <lupus@ximian.com>
782
783         * object.c: implement is_interned() the right way.
784
785 2002-03-21  Martin Baulig  <martin@gnome.org>
786
787         * debug-symfile.[ch]: New files to handle debugging information
788         files. There's also support to dynamically update these symbol
789         files to include machine dependent information.
790
791 2002-03-20  Dietmar Maurer  <dietmar@ximian.com>
792
793         * threads.c (mono_thread_create): new function to create thread
794         from C
795
796 2002-03-20  Martin Baulig  <martin@gnome.org>
797
798         * icall.c (ves_icall_InternalInvoke): Create a new object if the
799         method is a constructor.
800         (icall_map): Added "System.Reflection.MonoCMethod::InternalInvoke",
801         points to ves_icall_InternalInvoke().
802
803 2002-03-20  Dan Lewis <dihlewis@yahoo.co.uk>
804
805         * file-io.c: Flush shouldn't throw exceptions.
806
807 2002-03-19  Dan Lewis <dihlewis@yahoo.co.uk>
808
809         * file-io.c: FileStream flush support; FileSetLength now
810         restores file pointer.
811
812 Tue Mar 19 18:17:21 CET 2002 Paolo Molaro <lupus@ximian.com>
813
814         * class.c: set image for pointer classes.
815
816 2002/03/19  Nick Drochak <ndrochak@gol.com>
817
818         * sysmath.c: Forgot one.
819
820 2002-03-18  Miguel de Icaza  <miguel@ximian.com>
821
822         * sysmath.c: Avoid redefining existing names.
823
824 2002-03-18  Dan Lewis <dihlewis@yahoo.co.uk>
825
826         * sysmath.c, sysmath.h, icall.c, Makefile.am: math routines now
827         handled by runtime as icall rather than dllimport from libm.so
828         * file-io.c, file-io.h: fixed handle argument type.
829
830 2002-03-18  Dick Porter  <dick@ximian.com>
831
832         * reflection.c (mono_image_get_type_info): rename interface to
833         iface, because of "#define interface struct" on windows.
834
835 Sat Mar 16 19:18:38 CET 2002 Paolo Molaro <lupus@ximian.com>
836
837         * class.c, class.h: rename and export mono_ptr_class_get().
838         * metadata.c: support MONO_TYPE_ARRAY in MonoType compare.
839         * reflection.c, reflection.h, icall.c: better/saner type name
840         parsing and MonoType creation. Handle MONO_TYPE_ARRAY in
841         method signatures.
842
843 2002-03-14  Dietmar Maurer  <dietmar@ximian.com>
844
845         * class.c (mono_class_init): removed hardcoded GHC_SLOT
846
847         * icall.c (ves_icall_InternalInvoke): impl.
848
849 Wed Mar 13 00:27:30 CET 2002 Paolo Molaro <lupus@ximian.com>
850
851         * reflection.c: output the interface map table, too.
852
853 2002-03-12  Dietmar Maurer  <dietmar@ximian.com>
854
855         * class.c (class_compute_field_layout): separate computation of 
856         static field layout
857
858 2002-03-12  Dan Lewis <dihlewis@yahoo.co.uk>
859
860         * icall.c: added System.Buffer support.
861         * file-io.c: moved file icalls from PAL to FileStream.
862
863 2002-03-12  Dietmar Maurer  <dietmar@ximian.com>
864
865         * icall.c (ves_icall_System_Object_GetHashCode): impl.
866
867 2002-03-11  Dietmar Maurer  <dietmar@ximian.com>
868
869         * icall.c (ves_icall_System_ValueType_GetHashCode): impl.
870
871 Mon Mar 11 14:45:42 CET 2002 Paolo Molaro <lupus@ximian.com>
872
873         * verify.c, verify.h: moved here the corlib/runtime consistency checks.
874
875 Mon Mar 11 11:12:23 CET 2002 Paolo Molaro <lupus@ximian.com>
876
877         * debug-helpers.{c,h}: moved here from monograph some useful functions
878         to locate a method by name/signature in a class or image. Included
879         also a small and flexible IL disassembler.
880
881 Fri Mar 8 16:29:29 CET 2002 Paolo Molaro <lupus@ximian.com>
882
883         * reflection.c: fixup tokens in methods with small header size, too.
884
885 2002-03-08  Dietmar Maurer  <dietmar@ximian.com>
886
887         * object.c (mono_string_to_utf8): remove assert(!error), instead
888         print a warning. 
889
890 Thu Mar 7 18:55:15 CET 2002 Paolo Molaro <lupus@ximian.com>
891
892         * icall.c: update to the new mono_Array_class_get interface.
893
894 Thu Mar 7 17:23:26 CET 2002 Paolo Molaro <lupus@ximian.com>
895
896         * appdomain.c, object.c: Boehm-GC enable.
897         * icall.c: make get_data_chunk() support split data requests.
898         Ensure a class is initialized in more cases. Return only the first
899         property found in GetProperties() or the compiler gets confused. 
900         Implemented GetEvents(). Temporary fix to GetType(), needs rewriting.
901         * reflection.h, reflection.c: add fixup mechanism for field and method
902         tokens. Initialize assembly->typeref in a single place. Output
903         properties after events. Support custom attributes for events, too.
904         Typo fix for paramter custom attrs.
905
906 2002-03-07  Martin Baulig  <martin@gnome.org>
907
908         * icall.c (ves_icall_System_Array_FastCopy): Small fix.
909
910 2002-03-07  Dietmar Maurer  <dietmar@ximian.com>
911
912         * class.c (mono_array_class_get): fix. for multi. dim. arrays
913
914 2002-03-06  Martin Baulig  <martin@gnome.org>
915
916         * icall.c (ves_icall_System_Array_CreateInstanceImpl): Make this work with
917         non-zero lower bounds. See testcases #F10-#F13.
918
919 2002-03-05  Martin Baulig  <martin@gnome.org>
920
921         * exception.c (mono_get_exception_argument_out_of_range): New exception.
922
923         * icall.c (ves_icall_System_Array_GetValue): Moved actual implementation to
924         ves_icall_System_Array_GetValue(), only calculate the absolute array position
925         here.
926         (ves_icall_System_Array_SetValue): Likewise.
927         (ves_icall_System_Array_GetValueImpl): New interncall. Takes an array position
928         as argument and does the actual work. This function is used when copying a
929         multi-dimensional array.
930         (ves_icall_System_Array_SetValueImpl): Almost completely rewrote this. It can
931         now do all the widening conversions of value types.
932         (ves_icall_System_Array_CreateInstanceImpl): Implemented.
933
934 Tue Mar 5 18:14:01 CET 2002 Paolo Molaro <lupus@ximian.com>
935
936         * class.c: remove some magic numbers and use the smbolic names,
937         instead. Added init_events() to load event info at class init time.
938         * metadata.h, metadata.c: added mono_metadata_events_from_typedef()
939         and mono_metadata_methods_from_event().
940         * reflection.h, reflection.c: added support for writing out the evnets
941         related information.
942
943 Mon Mar 4 20:32:43 CET 2002 Paolo Molaro <lupus@ximian.com>
944
945         * reflection.h, icall.c: use a different method (GetInterfaces)
946         to gather interface info and add isbyref, isprimitive and
947         ispointer to the ves_icall_get_type_info() return value.
948
949 Mon Mar 4 11:22:26 CET 2002 Paolo Molaro <lupus@ximian.com>
950
951         * class.h: stared adding support for events.
952         * icall.c: split find_members implementation. Added debug icall to get
953         the address of an object.
954         * reflection.c: handle TypeBuilders in mono_type_get_object().
955
956 2002-03-01  Martin Baulig  <martin@gnome.org>
957
958         * icall.c (ves_icall_System_Array_GetLength): This must throw an
959         ArgumentOutOfRangeException(), not an ArgumentException().
960         (ves_icall_System_Array_GetLowerBound): Likewise.
961         (ves_icall_System_Array_GetValue): Improved argument checking.
962         (ves_icall_System_Array_SetValue): Improved argument checking.
963
964 2002-03-01  Martin Baulig  <martin@gnome.org>
965
966         * icall.c (ves_icall_System_Array_GetValue): Raise an exception when
967         called with invalid arguments rather than just dying with g_assert().
968         (ves_icall_System_Array_SetValue): Likewise.
969         (ves_icall_System_Array_CreateInstanceImpl): Don't g_assert_not_reached(),
970         raise a NotImplementedException instead.
971         (ves_icall_System_Array_GetLength): Added argument checking.
972         (ves_icall_System_Array_GetLowerBound): Added argument checking.
973
974 2002-03-01  Dietmar Maurer  <dietmar@ximian.com>
975
976         * object.h (mono_assert): new macros mono_assert and
977         mono_assert_not_reached
978
979 2002-02-28  Martin Baulig  <martin@gnome.org>
980
981         * icall.c: Rename "System::String::Intern" to "System::String::_Intern"
982         and "System::String::IsInterned" to "System::String::_IsInterned".
983
984 Thu Feb 28 19:19:35 CET 2002 Paolo Molaro <lupus@ximian.com>
985
986         * icall.c: remove hacks for typebuilder. Added icall to create a
987         modified type from a tybebuilder.
988         * reflection.c: removed hacks for TypeBuilder. Create also a MonoImage
989         in mono_image_basic_init (). Added mono_reflection_setup_internal_class ()
990         to create a backing MonoClass for a TypeBuilder.
991
992 Thu Feb 28 15:35:51 CET 2002 Paolo Molaro <lupus@ximian.com>
993
994         * class.c, class.h: more refactoring of class init.
995         Export mono_class_setup_mono_type() and mono_class_setup_parent().
996
997 Thu Feb 28 12:33:41 CET 2002 Paolo Molaro <lupus@ximian.com>
998
999         * marshal.c, marshal.h: start of marshaling interface.
1000
1001 Wed Feb 27 22:15:17 CET 2002 Paolo Molaro <lupus@ximian.com>
1002
1003         * icall.c: fix order in assembly qualified name icall.
1004
1005 Wed Feb 27 18:45:03 CET 2002 Paolo Molaro <lupus@ximian.com>
1006
1007         * class.c: do not free str, since we store it in the hash table.
1008         * reflection.h: add label field to MonoILExceptionInfo.
1009         * reflection.c: handle references to more than one assembly. Handle
1010         case when there isn't a module created in the assembly.
1011
1012 Wed Feb 27 12:35:10 CET 2002 Paolo Molaro <lupus@ximian.com>
1013
1014         * class.c: Fix typo. Start refactoring of class init code.
1015
1016 Wed Feb 27 12:23:00 CET 2002 Paolo Molaro <lupus@ximian.com>
1017
1018         * appdomain.c: exit with 1 on error.
1019         * class.c: we already have the name in MonoClassField.
1020         * image.c, image.h, metadata.c, pedump.c: use directly a pointer in
1021         MonoStreamHeader instead of an offset of image->raw_metadata.
1022
1023 2002-02-26  Miguel de Icaza  <miguel@ximian.com>
1024
1025         * appdomain.c (mono_init): Be even more descriptive about the error.
1026
1027 Tue Feb 26 16:18:07 CET 2002 Paolo Molaro <lupus@ximian.com>
1028
1029         * appdomain.c: give the user an informative message when corlib can't
1030         be loaded.
1031
1032 2002-02-26  Martin Baulig  <martin@gnome.org>
1033
1034         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData):
1035         New icall to get the time zone data.
1036
1037 Mon Feb 25 15:51:51 CET 2002 Paolo Molaro <lupus@ximian.com>
1038
1039         * reflection.c: set virtual and raw size of section correctly.
1040         * threads.c: transfer domain information to newly created threads.
1041
1042 Fri Feb 22 18:55:57 CET 2002 Paolo Molaro <lupus@ximian.com>
1043
1044         * class.c: when instancing a class in a domain, load the default
1045         vaules for static fields from the constant table. Fix System.Enum to
1046         not be an enum.
1047         * icall.c: implement Object::GetType() internalcall. Implemented
1048         MonoField::GetValue() internalcall. Avoid SEGV in search_method().
1049         Fixed checking of binding flags in find_members().
1050         * metadata.c, metadata.h: introduce mono_metadata_type_hash().
1051         * reflection.c: handle enumerations when writing to the constant
1052         table. Use a different object cache for types.
1053
1054
1055 2002-02-22  Dietmar Maurer  <dietmar@ximian.com>
1056
1057         * object.c (mono_object_isinst): fix for arrays
1058
1059         * icall.c (ves_icall_type_is_subtype_of): fix for 2 interfaces
1060
1061 Thu Feb 21 21:00:13 CET 2002 Paolo Molaro <lupus@ximian.com>
1062
1063         * object.c: don't use mprotect ()  and fix intern pool hash table
1064         lookup for big endian systems.
1065
1066 Thu Feb 21 19:30:29 CET 2002 Paolo Molaro <lupus@ximian.com>
1067
1068         * icall.c: change type_is_subtype_of () signature.
1069
1070 2002-02-21  Mark Crichton  <crichton@gimp.org>
1071
1072         * rand.c, rand.h: Added random number generator for
1073         System.Security.Cryptography classes.
1074
1075         * exception.c, exception.h: Added mono_get_exception_not_implemeted.
1076
1077         * icall.c: Added System.Security.Cryptography calls.
1078
1079 Thu Feb 21 16:45:34 CET 2002 Paolo Molaro <lupus@ximian.com>
1080
1081         * class.c, icall.c, metadata.c: better support for pointer types.
1082         Create a class for them as suggested by dietmar. Fix TYPE_ARRAY class.
1083         * reflection.c: Add support for getting custom attrs for properties
1084         and simplify some code.
1085
1086 Wed Feb 20 22:20:29 CET 2002 Paolo Molaro <lupus@ximian.com>
1087
1088         * icall.c: change getToken () and add custom attribute GetBlob()helper
1089         method.
1090         * reflection.h: add custom attrs array to the reflection builder structures.
1091         * reflection.c: encode and emit custom attributes for all the relevant
1092         reflection objects. Cache fieldref and methodref tokens. Change
1093         mono_image_create_token() interface to take a MonoDynamicAssembly.
1094         More complete custom attributes decoder. Load custom attributes for
1095         Assembly, Field, Method and Constructor objects, too. Make the
1096         returned array an Attribute[] one, not object[]. Added
1097         mono_reflection_get_custom_attrs_blob() to encode the arguments of a
1098         custom attribute constructor.
1099
1100 2002-02-20  Dick Porter  <dick@ximian.com>
1101
1102         * icall.c:
1103         * rawbuffer.c:
1104         * socket-io.c: Windows portability fixes (sometimes just ifdeffing
1105         problem code out for now).
1106
1107 2002-02-19  Radek Doulik  <rodo@ximian.com>
1108
1109         * object.c (mono_ldstr): use hash table to avoid multiple swapping
1110
1111 Tue Feb 19 20:23:11 CET 2002 Paolo Molaro <lupus@ximian.com>
1112
1113         * icall.c: register the GetCustomAttributes method.
1114         * object.c, object.h: add mono_string_new_len ().
1115         * reflection.h, reflection.c: added mono_runtime_invoke(),
1116         mono_install_runtime_invoke(). Added
1117         mono_reflection_get_custom_attrs () to load custom attributes and
1118         create the attribute objects.
1119
1120 2002-02-19  Dick Porter  <dick@ximian.com>
1121         * threads-dummy-types.c:
1122         * threads-dummy-types.h:
1123         * threads-dummy.c:
1124         * threads-dummy.h:
1125         * threads-pthread-types.c:
1126         * threads-pthread-types.h:
1127         * threads-pthread.c:
1128         * threads-pthread.h:  Deleted obsolete files
1129
1130 2002-02-19  Dietmar Maurer  <dietmar@ximian.com>
1131
1132         * class.c (mono_class_vtable): runtime init the class when we
1133         allocate static class data.
1134
1135         * icall.c (ves_icall_System_Array_SetValue): check for null values.
1136
1137         * appdomain.c (mono_domain_transfer_object): impl. hack for Arrays
1138         and String - but we will need generic marshalling support in the
1139         future. 
1140         (mono_init): set the domain name in a ms compatible way
1141
1142         * object.c (mono_string_new_utf16): bug fix: use char[] instead of
1143         String[].
1144
1145 2002-02-18  Dietmar Maurer  <dietmar@ximian.com>
1146
1147         * object.c (mono_array_clone): use alloca() instead of g_malloc  
1148         for sizes
1149
1150         * appdomain.c (mono_domain_unload): impl.
1151
1152 Mon Feb 18 15:52:20 CET 2002 Paolo Molaro <lupus@ximian.com>
1153
1154         * appdomain.c, object.c: fix intern pool implementation.
1155         * class.c: fix alignment code.
1156
1157 2002-02-16  Radek Doulik  <rodo@ximian.com>
1158
1159         * icall.c (ves_icall_System_Enum_ToObject): in case of big endian
1160         and s2 > s1, just copy lower bytes to be compatible with little
1161         endian (i.e. 64bit value & 0xffffffff --> 32bit value)
1162         (ves_icall_System_Enum_ToObject): and likewise for s1 > s2
1163
1164         * unicode.c (ves_icall_iconv_new_encoder): decide on big_endian,
1165         force big_endian to be 1 for big endian machines 
1166         (ves_icall_iconv_new_decoder): ditto
1167
1168 2002-02-16  Jeffrey Stedfast  <fejj@ximian.com>
1169
1170         * socket-io.c (convert_sockopt_level_and_name): If the system
1171         doesn't define SOL_IP or SOL_TCP, get them by hand using
1172         getprotobyname() and caching the values (because this could be a
1173         slow operation).
1174         (ves_icall_System_Net_Sockets_Socket_SetSocketOption_internal):
1175         Use the appropriate struct when the system does support it. Ie,
1176         not all systems have struct ip_mreqn so use struct ip_mreq when
1177         appropriate.
1178
1179 Fri Feb 15 18:15:44 CET 2002 Paolo Molaro <lupus@ximian.com>
1180
1181         * reflection.c: handle finally clauses.
1182
1183 Fri Feb 15 15:06:33 CET 2002 Paolo Molaro <lupus@ximian.com>
1184
1185         * socket-io.c: use g_snprintf() instead of snprintf.
1186
1187 2002-02-14  Jeffrey Stedfast  <fejj@ximian.com>
1188
1189         * reflection.c (mono_param_get_objects): Cast second argument to
1190         mono_method_get_param_names to a const char** to silence the
1191         compiler warning.
1192
1193         * appdomain.c (mono_domain_assembly_open): Put parens around the
1194         truth statement in the for-loop.
1195
1196         * unicode.c (iconv_convert): Got rid of a compiler warning about
1197         int i being unused when the system has a new iconv.
1198         (iconv_get_length): Same.
1199
1200         * image.c (load_class_names): Cast the second argument to
1201         g_hash_table_insert() to char* to hush compiler warnings about the
1202         arg being a const.
1203         (mono_image_open): Same here.
1204
1205         * socket-io.c: Don't conditionally include sys/filio.h or
1206         sys/sockio.h here anymore since we now get them from
1207         io-layer/io-layer.h
1208         (inet_pton): If the system doesn't support inet_aton, implement
1209         using inet_addr and also #define INADDR_NONE if it isn't defined
1210         by the system.
1211
1212 Thu Feb 14 19:01:06 CET 2002 Paolo Molaro <lupus@ximian.com>
1213
1214         * metadata.c, metadata.h: added function to get packing and size info
1215         of a typedef.
1216         * reflection.h, reflection.c: handle field RVA data. Save info about
1217         the table layout if needed. Assign typedef indexes to all the types
1218         before dumping the info about them to avoid forward reference problems.
1219
1220 2002-02-14  Dietmar Maurer  <dietmar@ximian.com>
1221
1222         * socket-io.c (convert_sockopt_level_and_name): ifdef
1223         SO_ACCEPTCONN because it is not defined on my system (old debian)
1224
1225 Thu Feb 14 11:49:30 CET 2002 Paolo Molaro <lupus@ximian.com>
1226
1227         * opcode.c: use stddef.h to get NULL.
1228
1229 2002-02-14  Jeffrey Stedfast  <fejj@ximian.com>
1230
1231         * socket-io.c: conditionally include sys/filio.h and sys/sockio.h
1232         for FIONBIO, FIONREAD and SIOCATMARK.
1233         (ves_icall_System_Net_Dns_GetHostByAddr_internal): SunOS doesn't
1234         define INADDR_NONE and besides, inet_addr() is deprecated and
1235         should not be used. Use inet_pton() instead - it also has the
1236         added bonus that it can easily handle IPv6 addresses as well.
1237         (inet_pton): Implement using inet_aton() ifndef HAVE_INET_PTON.
1238
1239 Wed Feb 13 23:00:21 CET 2002 Paolo Molaro <lupus@ximian.com>
1240
1241         * decimal.c: remove _MSC_VER conditional.
1242
1243 2002-02-13  Dick Porter  <dick@ximian.com>
1244
1245         * socket-io.c: 
1246         * icall.c: Internal calls for Blocking, Select, Shutdown,
1247         GetSocketOption and SetSocketOption
1248
1249 Wed Feb 13 19:20:01 CET 2002 Paolo Molaro <lupus@ximian.com>
1250
1251         * assembly.cs: better resolver: use it instead of some kludgy
1252         code.
1253
1254 Wed Feb 13 18:25:55 CET 2002 Paolo Molaro <lupus@ximian.com>
1255
1256         * reflection.c: the best way to speed-up the compiler is to avoid
1257         infinite loops.
1258
1259 2002-02-13  Dietmar Maurer  <dietmar@ximian.com>
1260
1261         * class.c (mono_class_vtable): changed the object layout
1262         (obj->vtable->class). 
1263         (mono_class_create_from_typespec): consider MONO_TYPE_PTR
1264
1265 Tue Feb 12 20:06:01 CET 2002 Paolo Molaro <lupus@ximian.com>
1266
1267         * assembly.c: look for assemblies in the assembly dir, too.
1268
1269 Tue Feb 12 14:03:42 CET 2002 Paolo Molaro <lupus@ximian.com>
1270
1271         * class.c: fix thinko in mono_class_from_type().
1272
1273 Mon Feb 11 19:43:51 CET 2002 Paolo Molaro <lupus@ximian.com>
1274
1275         * exception.h, exception.c: added TypeLoadException.
1276         * object.h, object.c: added mono_array_clone ().
1277         * icall.c: handle throwOnError in AssemblyGetType().
1278         Added Array.Clone().
1279         * opcode.h, opcode.c: use a single value for the opcode val.
1280         Compile fix for non-gcc compilers.
1281
1282 Fri Feb 8 12:26:37 CET 2002 Paolo Molaro <lupus@ximian.com>
1283
1284         * opcodes.c, opcodes.h: export interesting info about opcodes.
1285
1286 2002-02-05  Dietmar Maurer  <dietmar@ximian.com>
1287
1288         * object.h (MONO_CHECK_ARG, MONO_CHECK_ARG_NULL): new macro for
1289         icalls. 
1290
1291         * class.c (class_compute_field_layout): set element_class for enums
1292         (mono_class_create_from_typedef): set element_class for normal classes
1293
1294         * icall.c (ves_icall_System_Enum_get_value): impl.
1295
1296         * class.c (mono_class_create_from_typedef): do not set valuetype
1297         flag for System.ValueType and System.Enum
1298
1299 2002-02-04  Dietmar Maurer  <dietmar@ximian.com>
1300
1301         * unicode.c (iconv_convert): fix big endian problem.
1302
1303 Fri Feb 1 16:13:20 CET 2002 Paolo Molaro <lupus@ximian.com>
1304
1305         * class.c: add asserts if we are ever going to scribble over memory.
1306         * socket-io.c: not all systems have AF_IRDA defined.
1307
1308 2002-01-31  Dietmar Maurer  <dietmar@ximian.com>
1309
1310         * class.c (class_compute_field_layout): do not consider static
1311         fields to compute alignment
1312
1313 2002-01-25  Dietmar Maurer  <dietmar@ximian.com>
1314
1315         * appdomain.c (mono_appdomain_get): impl.
1316         (ves_icall_System_AppDomain_ExecuteAssembly): impl.
1317
1318 Thu Jan 24 12:59:23 CET 2002 Paolo Molaro <lupus@ximian.com>
1319
1320         * icall.c: ignore "file://" prefix when loading an assembly.
1321
1322 2002-01-23  Dick Porter  <dick@ximian.com>
1323
1324         * socket-io.c:
1325         * icall.c:
1326         * Makefile.am: Added socket support
1327
1328 2002-01-23  Miguel de Icaza  <miguel@ximian.com>
1329
1330         * icall.c (ves_icall_appdomain_get_default_assemblies): put this
1331         code back.  This should return the assemblies that are loaded by
1332         the runtime on behalf of an application domain. 
1333
1334         The current implementation is still broken, it just returns every
1335         assembly loaded, but until we get real applications domain this
1336         will do.
1337
1338 2002-01-23  Dietmar Maurer  <dietmar@ximian.com>
1339
1340         * icall.c (ves_icall_appdomain_get_cur_domain): runtime_init the
1341         AppDomain object.
1342
1343 2002-01-23  Miguel de Icaza  <miguel@ximian.com>
1344
1345         * icall.c (ves_icall_appdomain_get_cur_domain): Cache the value of
1346         the mono_class_from_name lookup.
1347         (ves_icall_get_parameter_info): ditto.
1348         (ves_icall_appdomain_get_assemblies, add_assembly): Implement new internal
1349         method.
1350         (ves_icall_System_Reflection_Assembly_get_code_base): Another new call.
1351
1352 Tue Jan 22 22:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
1353
1354         * class.c: load also nested classes on class init.
1355         System.ValueType instance methods gets passed boxed
1356         values, unless methods in derived classed that get a pointer to the
1357         data.
1358         * icall.c: use better name parsing code in GetType().
1359         * image.c, image.h: add mono_image_loaded ().
1360         * metadata.c, metadata.h: add mono_metadata_nesting_typedef ().
1361         * reflection.c, reflection.h: added mono_reflection_parse_type().
1362
1363 2002-01-22  Veronica De Santis <veron78@interfree.it>
1364
1365         * icall.c : Added mapping of internal calls for Manual and Auto reset events
1366         * threads.c : Added the implementation of internal calls for events
1367         * threads.h : Added prototypes of internal calls for events
1368         
1369 2002-01-21  Radek Doulik  <rodo@ximian.com>
1370
1371         * icall.c (ves_icall_InitializeArray): swap bytes on big endians
1372
1373 2002-01-21  Dietmar Maurer  <dietmar@ximian.com>
1374
1375         * class.c (mono_class_init): set min_align to 1 (instead of 0)
1376         (mono_class_value_size): use min_align
1377
1378 2002-01-20  Dick Porter  <dick@ximian.com>
1379
1380         * threads.h:
1381         * threads.c: Replaced all instances of WapiHandle * with HANDLE,
1382         so it compiles on w32.
1383
1384 2002-01-17  Dietmar Maurer  <dietmar@ximian.com>
1385
1386         * metadata.c (mono_type_stack_size): impl.
1387
1388         * class.c (mono_class_get_field): impl. memberref token
1389
1390 2002-01-16 Veronica De Santis <veron78@@interfree.it>
1391
1392         * icall.h : Added the internal calls mapping for CreateMutex_internal
1393                     and ReleaseMutex_internal.
1394         * threads.h : Added the prototype of mutexes internal calls.
1395         * threads.c : Added the implementations of mutexes internal calls.
1396
1397 Tue Jan 15 22:47:57 CET 2002 Paolo Molaro <lupus@ximian.com>
1398
1399         * metaparse.h: removed unused file.
1400         * reflection.c, reflection.h: added stream_data_align () function 
1401         to align data in streams and keep stream aligned. Add support for
1402         exception support in method headers.
1403
1404 Tue Jan 15 19:42:50 CET 2002 Paolo Molaro <lupus@ximian.com>
1405
1406         * unicode.c: make iconv_convert () return the number of bytess written
1407         in the output buffer.
1408
1409 2002-01-15  Dick Porter  <dick@ximian.com>
1410         * threads.c: Make the runtime's idea of infinite timeouts coincide
1411         with the class library's
1412
1413         Fix a particularly egregious bug in mono_thread_cleanup(). That
1414         code was so utterly bogus it must have been written on a Monday.
1415
1416 Mon Jan 14 17:01:03 CET 2002 Paolo Molaro <lupus@ximian.com>
1417
1418         * reflection.h: add subtypes field to TypeBuilder.
1419         * reflection.c: encode constants for literal fields.
1420         Handle subtypes. Fix user string token (and add a zero byte)
1421         at the end.
1422         
1423 2002-01-14  Dietmar Maurer  <dietmar@ximian.com>
1424
1425         * class.c (mono_class_init): bug fix: assign slot numbers for
1426         abstract methods.
1427
1428 Fri Jan 11 18:54:42 CET 2002 Paolo Molaro <lupus@ximian.com>
1429
1430         * reflection.c: don't try to output a code RVA for abstract methods.
1431         Small fixes for method header format. Output parameter info to the
1432         ParamDef table. Save method overriding info to MethodImpl table.
1433         Fix property support. Allow typedef.extends to be a type in the
1434         building assembly.
1435         * verify.c: fix off-by-one error.
1436
1437 Thu Jan 10 19:36:27 CET 2002 Paolo Molaro <lupus@ximian.com>
1438
1439         * class.c: fix mono_class_from_mono_type () for szarray types.
1440         Remove unused cache check in mono_class_from_type_spec().
1441         * icall.c: *type_from_name () functions handle simple arrays and byref.
1442         * reflection.c: handle byref and szarray types. Handle methods without
1443         body (gets P/Invoke compilation working). Handle types and fields in
1444         get_token ().
1445         * reflection.h: add rank to MonoTypeInfo.
1446
1447 2002-01-10  Dick Porter  <dick@ximian.com>
1448
1449         * threads.c: Implemented WaitAll(), WaitAny() and WaitOne()
1450         internal calls
1451
1452 Wed Jan 9 19:27:13 CET 2002 Paolo Molaro <lupus@ximian.com>
1453
1454         * icall.c: initialize class in type_from_handle ().
1455         Loop also in parent classes for get_method ().
1456         * reflection.c: properly encode class and valuetype types.
1457         Start on encoding TypeBuilder types. Handle fieldrefs.
1458         Use correct length when registering a user string.
1459         Handle ConstructorBuilder and MonoMethod in get_token ().
1460         Make mono_type_get_object () aware of cached types.
1461         * object.c: back out change to mono_string_new ().
1462
1463 Tue Jan 8 22:47:44 EST 2002 Matt Kimball <matt@kimball.net>
1464         * object.c: mono_string_new should return a NULL when the string 
1465         passed in is NULL -- not try to deference it.
1466         
1467 Sat Jan 5 15:48:04 CET 2002 Paolo Molaro <lupus@ximian.com>
1468
1469         * icall.c: hack to make IsSubType work for TypeBuilders.
1470         * reflection.c: emit constructors before methods.
1471         Retrieve param names in mono_param_get_objects().
1472
1473 2002/01/05  Nick Drochak  <ndrochak@gol.com>
1474
1475         * Makefile.am: fix list of headers and sources so automake 1.5
1476         doesn't complain. Removed \# at end of list.
1477
1478 Thu Jan 3 23:17:17 CET 2002 Paolo Molaro <lupus@ximian.com>
1479
1480         * reflection.c: get token for a method ref. Set return type of
1481         constructor to void.
1482         * loader.c: debug message.
1483         * class.c: typo fix.
1484
1485 Mon Dec 24 17:18:10 CET 2001 Paolo Molaro <lupus@ximian.com>
1486
1487         * icall.c: fix array init with rank > 1. FindMembers
1488         loops in parent class as well.
1489         * image.c: do not insert nested types in name cache.
1490         * reflection.c: warning fix.
1491         * reflection.h: add override method (for interface impl).
1492
1493 Mon Dec 24 16:16:56 CET 2001 Paolo Molaro <lupus@ximian.com>
1494
1495         * metadata.c: fix customattr decoding.
1496
1497 2001-12-21  Miguel de Icaza  <miguel@ximian.com>
1498
1499         * rawbuffer.cs: Added native Win32 implementation, avoids using
1500         mmap on Cygwin.  This patch is from Dan Lewis (dihlewis@yahoo.co.uk)
1501
1502 Thu Dec 20 20:11:26 CET 2001 Paolo Molaro <lupus@ximian.com>
1503
1504         * class.c: make the low-level routines handle the cache.
1505
1506 Thu Dec 20 15:20:35 CET 2001 Paolo Molaro <lupus@ximian.com>
1507
1508         * image.c: fopen (file, "rb") ("David Dawkins" <david@dawkins.st>).
1509
1510 Tue Dec 18 18:50:00 CET 2001 Paolo Molaro <lupus@ximian.com>
1511
1512         * class.c: fix mono_array_element_size() for objects.
1513         * class.h, class.c: add properties to MonoClass and load them
1514         at init time.
1515         * icall.c: check with isinst() when assigning a value to an array
1516         instead of requiring the classes to match exactly.
1517         Implemented icall for System.Type::GetType().
1518         Implemented icalls to get ParameterInfo, ProprtyInfo and info about
1519         enums. Handle bindingflags when looking for methods and fields.
1520         * metadata.h, metadata.c: implemented mono_metadata_properties_from_typedef()
1521         and mono_metadata_methods_from_property().
1522         * reflection.h, reflection.c: added structures for propreties,
1523         parameters and enums. Implemented mono_property_get_object() and
1524         mono_param_get_objects().
1525
1526 2001-12-18  Dick Porter  <dick@ximian.com>
1527
1528         * file-io.c: Use mono_string_to_utf16() instead of
1529         mono_string_chars()
1530
1531         * object.c: Added mono_string_to_utf16(), which copies the non
1532         NULL-terminated MonoString into a new double-null-terminated
1533         buffer.
1534
1535 2001-12-17  Dietmar Maurer  <dietmar@ximian.com>
1536
1537         * icall.c (ves_icall_System_DateTime_GetNow): added EPOCH adjustment
1538
1539 2001-12-16  Dietmar Maurer  <dietmar@ximian.com>
1540
1541         * file-io.c: raise exceptions if handle is invalid.
1542
1543 Thu Dec 13 20:27:08 CET 2001 Paolo Molaro <lupus@ximian.com>
1544
1545         * assembly.c: yet another check for mscorlib.
1546         * class.c, class.h: load nesting info for classes.
1547         * icall.c: many new functions to support the Reflection classes.
1548         * metadata.c, metadata.h: mono_metadata_nested_in_typedef() added.
1549         * reflection.h, reflection.c: mono_image_create_token(),
1550         mono_assembly_get_object(), mono_type_get_object(),
1551         mono_method_get_object(), mono_field_get_object(): methods to return
1552         objects that parallel the C representation of assemblies, types,
1553         methods, fields.
1554
1555 2001-12-11  Dick Porter  <dick@ximian.com>
1556
1557         * icall.c:
1558         * file-io.c: Internal calls for file IO.
1559
1560 Thu Dec 6 16:21:30 CET 2001 Paolo Molaro <lupus@ximian.com>
1561
1562         * tabledefs.h: missing FileAttributes.
1563         * verify.h, verify.c: use is_valid_string () to simplify and check for
1564         valid strings more correctly. Fix warnings and speeling.
1565         Check more tables: Filed, File, ModuleRef, StandAloneSig.
1566         Check code: branches, maxstack, method calls.
1567
1568 2001-12-04  Dietmar Maurer  <dietmar@ximian.com>
1569
1570         * object.c (mono_object_allocate): removed static, so that the jit
1571         can allocate value types.
1572
1573         * icall.c (ves_icall_System_DateTime_GetNow): impl.
1574
1575 Mon Dec 3 17:02:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1576
1577         * class.c: init enum types right away and register the
1578         token->MonoClass map in mono_class_create_from_typedef ().
1579         * verify.h, verify.c: first cut of the verifier.
1580         * pedump.c: add --verify switch to verify metadata tables.
1581         * tabledefs.h: add some missing enums.
1582
1583 2001-11-30  Dietmar Maurer  <dietmar@ximian.com>
1584
1585         * class.c (mono_install_runtime_class_init): impl.
1586         (mono_class_init): renamed mono_class_metadata_init to
1587         mono_class_init, also removed the metadata_inited flag
1588
1589         * object.c (mono_object_isinst): use faster algorithm
1590
1591 2001-11-30  Radek Doulik  <rodo@ximian.com>
1592
1593         * mono-endian.h: reverted last change
1594         added function prototypes
1595
1596         * Makefile.am (libmetadata_a_SOURCES): reverted my last change and
1597         add mono-endian.c back
1598
1599         * mono-endian.c: returned back, as Paolo pointed out, it's needed
1600         for unaligned access, I've mistaked it with endianess. I am
1601         sorry.
1602         (mono_read16): fix reverted endianess
1603         (mono_read64): ditto
1604         (mono_read32): ditto
1605
1606 2001-11-30  Dick Porter  <dick@ximian.com>
1607
1608         * exception.c: Implement mono_exception_from_name()
1609
1610 Fri Nov 30 12:01:02 CET 2001 Paolo Molaro <lupus@ximian.com>
1611
1612         * metadata.h, metadata.c: remove params_size and locals_size and their
1613         calculation from the metadata code: they are only usefult to the
1614         interp.
1615
1616 2001-11-29  Radek Doulik  <rodo@ximian.com>
1617
1618         * object.c (mono_ldstr): swap bytes here, it's probably not the
1619         best place, but works for me now, I'll redo it once I know mono
1620         better, also note that I add PROT_WRITE and don't reset back, also
1621         note that it's only affects big endians, so x86 should be OK
1622
1623         * mono-endian.h (read16): use just glib macros for both endians
1624
1625         * mono-endian.c: removed as glib macros are used in in
1626         mono-endian.h so we don't need to care about endianess for read
1627         macros as glib does that for us already
1628
1629 Thu Nov 29 18:20:58 CET 2001 Paolo Molaro <lupus@ximian.com>
1630
1631         * class.h, class.h: take minimum alignment into consideration so
1632         that the fields of a class remain aligned also when in an array.
1633
1634 Tue Nov 27 16:39:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1635
1636         * loader.h, loader.c: add mono_method_get_param_names().
1637         * class.c: 0-init class fields.
1638
1639 2001-11-26  Dick Porter  <dick@ximian.com>
1640
1641         * icall.c:
1642         * threads-types.h:
1643         * threads.c: New file that handles System.Threading on all platforms
1644
1645         * object.c: 
1646         * object.h: Remove the synchronisation struct from MonoObject,
1647         replace it with a pointer that gets initialised on demand
1648
1649         * Makefile.am: Replace all the system-specific threading code with
1650         a single file that uses the new wrapper library
1651
1652 Mon Nov 19 11:37:14 CET 2001 Paolo Molaro <lupus@ximian.com>
1653
1654         * class.c, class.h: add mono_install_trampoline() so that the runtime
1655         can register a function to create a trampoline: removes the ugly
1656         requirement that a runtime needed to export arch_create_jit_trampoline.
1657         * object.h, object.c: added mono_install_handler() so that the runtime
1658         can install an handler for exceptions generated in C code (with
1659         mono_raise_exception()). Added C struct for System.Delegate.
1660         * pedump.c: removed arch_create_jit_trampoline.
1661         * reflection.c: some cleanups to allow registering user strings and
1662         later getting a token for methodrefs and fieldrefs before the assembly
1663         is built.
1664         * row-indexes.h: updates and fixes from the new ECMA specs.
1665
1666 Thu Nov 15 17:44:49 CET 2001 Paolo Molaro <lupus@ximian.com>
1667
1668         * class.h, class.c: add enum_basetype field to MonoClass.
1669         * metadata.h, metadata.c: add mono_metadata_get_constant_index()
1670         to get index in the constant table reated to a field, param or
1671         property.
1672         * reflection.h, reflection.c: handle constructors. Set public-key and
1673         version number of the built assembly to 0.
1674         * row-indexes.h: update from new ECMA spec.
1675
1676 Wed Nov 14 19:26:06 CET 2001 Paolo Molaro <lupus@ximian.com>
1677
1678         * class.h, class.c: add a max_interface_id to MonoClass.
1679         * icall.c: rename my_mono_new_object() to my_mono_new_mono_type()
1680         since it's used to do that. Added mono_type_type_from_obj().
1681         Make GetType() return NULL instead of segfaulting if the type was not
1682         found. Handle simple arrays in assQualifiedName.
1683         * object.h: add a struct to represent an Exception.
1684         * reflection.c: output call convention in method signature.
1685         Add code to support P/Invoke methods and fixed offsets for fields.
1686
1687 Mon Nov 12 12:41:32 CET 2001 Paolo Molaro <lupus@ximian.com>
1688
1689         * decimal.c, decimal.h: mono_double2decimal() get the sign bit from
1690         the value.
1691         * icall.c: use mono_array_addr instead of array->vector: fixes the
1692         reflection image writing.
1693         * reflection.c: init call convention byte to 0 in method signature.
1694         Encode the property signature. Don't output property-related methods
1695         twice. Really process the properties for a type (don't cast a field to
1696         a property, my mom always told me that).
1697         Fix 64 bit issues in pointer alignment in a different and more
1698         readable way.
1699
1700 2001-11-10  Sean MacIsaac  <macisaac@ximian.com>
1701
1702         * loader.h: Removed type class from MonoDefaults, added monotype
1703
1704         * loader.c: Loaded MonoType, removed loading of Type
1705
1706         * icall.c (my_mono_new_object): Now returns a System.MonoType,
1707         and fills in System.Type._impl with a RuntimeTypeHandle rather
1708         than the actual MonoClass *
1709
1710         (ves_icall_type_from_handle): change from type_class to
1711         monotype_class
1712
1713         (ves_icall_System_Runtime_InteropServices_Marshal_ReadIntPtr):
1714         implemented
1715
1716         (ves_icall_System_Runtime_InteropServices_Marshal_PtrToStringAuto):
1717         implemented
1718
1719         (ves_icall_System_Reflection_Assembly_LoadFrom): implemented
1720
1721         (ves_icall_System_Reflection_Assembly_GetType): implemented
1722
1723         (ves_icall_System_MonoType_assQualifiedName): implemented
1724
1725         (ves_icall_System_PAL_OpSys_GetCurrentDirecotry): implemented
1726
1727 2001-11-09  Miguel de Icaza  <miguel@ximian.com>
1728
1729         * assembly.c (mono_assembly_open): Implement a cache for the
1730         assemblies. 
1731
1732         (mono_assembly_close): only destroy the assembly when the last
1733         reference is gone.
1734         
1735 2001-11-09  Dick Porter  <dick@ximian.com>
1736
1737         * Makefile.am (pedump_LDADD): Don't need THREAD_LIBS any more
1738
1739 2001-11-09  Dietmar Maurer  <dietmar@ximian.com>
1740
1741         * class.c (mono_class_metadata_init): bug fix: compute the right slot
1742
1743 Fri Nov 9 15:48:02 CET 2001 Paolo Molaro <lupus@ximian.com>
1744
1745         * icall.c, decimal.h, decimal.c: integrated decimal internalcalls
1746         from Martin Weindel.
1747         * object.h: add mono_string_chars ().
1748
1749 2001-11-07  Miguel de Icaza  <miguel@ximian.com>
1750
1751         * reflection.c (build_compressed_metadata): Eliminates warnings
1752         and uses 64-bit clean code.
1753
1754         * metadata.c (mono_type_hash): Change signature to eliminate warnings.
1755         (mono_type_equal): Change signature to eliminate warnings.
1756
1757 Wed Nov 7 15:40:01 CET 2001 Paolo Molaro <lupus@ximian.com>
1758
1759         * icall.c, loader.c: remove the internalcall array constructors.
1760         Changes to match the new MonoArray structure.
1761         * object.h, object.c: an array object doesn't allocate an extra
1762         vector. Add mono_array_new_full () to create jagged arrays easily.
1763
1764 Mon Nov 5 19:51:06 CET 2001 Paolo Molaro <lupus@ximian.com>
1765
1766         * metadata.h, metadata.c: add mono_metadata_field_info () to
1767         retreive all the info about a field from vairous tables.
1768         * icall.c: implement S.Runtime.CServices::InitializeArray () icall.
1769         * class.h, class.c: augment MonoClassField with more info.
1770         Implemented mono_ldtoken for fields. Implemented ExplicitLayout
1771         policy and load a field's RVA if needed.
1772
1773 2001-11-05  Dietmar Maurer  <dietmar@ximian.com>
1774
1775         * class.c (mono_class_metadata_init): create a trampoline for all
1776         virtual functions instead of actually compiling them.
1777
1778 Fri Nov 2 19:37:51 CET 2001 Paolo Molaro <lupus@ximian.com>
1779
1780         * class.h, class.c: include name in MonoClassField.
1781         * class.c: fix fundamental type of System.Object and System.String.
1782         Set the right fundamental type for SZARRAY, too. Handle TypeSpec
1783         tokens in ldtoken.
1784         * icall.c: remove internalcalls for the Reflection stuff that is now
1785         done in C# code.
1786         * loader.c: mono_field_from_memberref () implementation.
1787         * mono-endian.c: thinko (s/struct/union/g).
1788         * object.c, object.h: make the mono_string_* prototypes actually use
1789         MonoString instead of MonoObject.
1790         * reflection.c, reflection.h: updates for changes in the reflection
1791         code in corlib: we use C structures that map to the actual C# classes.
1792         Handle SZARRAYs when encoding types. Handle locals in methods. Use a
1793         fat method header if needed and use the info from the ILGenerator for
1794         methods. Handle fields in types. Misc fixes.
1795
1796 2001-10-17  Dietmar Maurer  <dietmar@ximian.com>
1797
1798         * class.c (mono_class_metadata_init): bug fix: always allocate
1799         space for static class data
1800
1801 2001-10-25  Dietmar Maurer  <dietmar@ximian.com>
1802
1803         * class.c (mono_compute_relative_numbering): use relative
1804         numbering to support fast runtime type checks.
1805
1806 2001-10-17  Sean MacIsaac  <macisaac@ximian.com>
1807
1808         * class.c (mono_class_create_from_typeref): added debugging output
1809         to print class name when MonoDummy is returned instead of real class
1810
1811 2001-10-15  Dietmar Maurer  <dietmar@ximian.com>
1812
1813         * class.c (mono_class_metadata_init): interface offset table now
1814         contains pointers into the vtable - this is more efficient for the jit
1815
1816 2001-10-12  Dietmar Maurer  <dietmar@ximian.com>
1817
1818         * class.c (mono_class_metadata_init): use a temporary vtable (the
1819         old algorithm only worked for the interpreter, but not for the jit)
1820
1821 2001-10-11  Dietmar Maurer  <dietmar@ximian.com>
1822
1823         * loader.c (method_from_memberref): use mono_class_get to get the
1824         class of an array instead of using System.Array directly.
1825         (mono_get_method): also add MEMBERREF methods to the method cache
1826         which usefull for arrays.
1827
1828 2001-10-10  Dietmar Maurer  <dietmar@ximian.com>
1829
1830         * pedump.c (arch_compile_method): added to compute vtable entry
1831
1832         * metadata.c (mono_metadata_interfaces_from_typedef): also return the
1833         number of interfaces.
1834         
1835         * class.h: merged MonoArrayClass into MonoClass
1836
1837         * class.c (mono_class_create_from_typedef): compute the vtable size and
1838         allocate space to include the vtable inside MonoClass
1839         (mono_class_metadata_init): initialize the vtable
1840
1841 Mon Oct 8 16:12:38 CEST 2001 Paolo Molaro <lupus@ximian.com>
1842
1843         * metadata.c, metadata.h: use MonoArrayType to describe the shape of an array.
1844         Guard against calling bsearch with a NULL pointer (pointed out by Laurent Rioux, smoux).
1845         * image.c: endian fixes by Laurent Rioux.
1846         * object.h, object.c: rename MonoStringObject to MonoString and
1847         MonoArrayObject to MonoArray. Change some function names to conform to
1848         the style mono_<object>_<action>. mono_string_new_utf16 () takes a
1849         guint16* as first argument, so don't use char*.
1850         Provide macros to do the interesting things on arrays in a portable way.
1851         * threads-pthread.c: updates for the API changes and #include <sched.h>
1852         (required for sched_yield()).
1853         * icall.c: updates for the API changes above.
1854         * Makefile.am, mono-endian.c. mono-endian.h: include unaligned read routines for
1855         platforms that need them.
1856
1857 Mon Oct 8 10:43:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
1858
1859         * class.c: set the correct type for all the fundamental
1860         type when loading the class.
1861
1862 2001-10-05  Dick Porter  <dick@ximian.com>
1863
1864         * threads-pthread.c (pthread_mutex_timedlock): Simple
1865         compatibility version for C libraries that lack this call.
1866
1867 Thu Oct 4 19:10:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
1868
1869         * class.c: MonoTypes stored in MonoClass are stored as
1870         fundamental MonoTypes when the class represents a
1871         fundamental type (System.Int32, ...).
1872         The TypeHandle return by ldtoken is a MonoType*.
1873         * icall.c: ves_icall_get_data_chunk () write out all the
1874         PE/COFF stuff. Implement ves_icall_define_method (),
1875         ves_icall_set_method_body (), ves_icall_type_from_handle ().
1876         * image.c: properly skip unknown streams.
1877         * loader.h, loader.c: add type_class to mono_defaults.
1878         * metadata.c, metadata.h: export compute_size () as
1879         mono_metadata_compute_size () with a better interface.
1880         Typo and C&P fixes.
1881         * pedump.c: don't try to print the entry point RVA if there is no entry point.
1882         * reflection.c, reflection.h: many cleanups, fixes, output method
1883         signatures and headers, typedef and typeref info, compress the metadata
1884         tables, output all the heap streams, cli header etc.
1885         * row-indexes.h: typo fixes.
1886
1887 2001-10-04  Dick Porter  <dick@ximian.com>
1888
1889         * object.h: Add a synchronisation mutex struct to MonoObject
1890
1891         * object.c (mono_new_object): Initialise the object
1892         synchronisation mutexes
1893
1894         * icall.c: System.Threading.Monitor internal calls
1895         
1896         * threads-pthread.h:
1897         * threads-pthread.c: System.Threading.Monitor internal calls
1898
1899         * threads-types.h: New file, includes the system-specific thread
1900         structures
1901         
1902         * threads-pthread-types.h:
1903         * threads-pthread-types.c: New files, handle pthread-specific
1904         synchronisation types
1905
1906         * threads-dummy-types.h: 
1907         * threads-dummy-types.c: New files of dummy support for
1908         thread-specific types
1909
1910         * metadata.c:
1911         * image.c:
1912         * pedump.c: include mono-endian.h not endian.h
1913         
1914         * Makefile.am: More threads files.
1915         Name mono-endian.h not endian.h
1916
1917 Tue Oct 2 20:33:48 CEST 2001 Paolo Molaro <lupus@ximian.com>
1918
1919         * Makefile.am, reflection.h, reflection.c: move here the reflection related 
1920         stuff and implement a few more bits.
1921         * icall.c: a field needs to be dereferenced twice. Do not use the same
1922         name for two variables in the same scope.
1923         * image.c, image.h: cleanups.
1924
1925 2001-10-02  Dietmar Maurer  <dietmar@ximian.com>
1926
1927         * class.c (mono_class_metadata_init): bug fix: compute the right size
1928
1929 Mon Oct 1 20:43:57 CEST 2001 Paolo Molaro <lupus@ximian.com>
1930
1931         * icall.c: implemented some of the Reflection internalcalls.
1932         * image.c, image.h: start writing out the PE/COFF image.
1933         * metadata.h, metadata.c: implement mono_metadata_encode_value ()
1934         that does the reverse than decode_blob_size ().
1935         * object.c: use mono_metadata_encode_value (). Move here
1936         temporary implementation of mono_string_to_utf8 ().
1937         * rawbuffer.c: make malloc_map static.
1938
1939 Fri Sep 28 19:26:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
1940
1941         * metadata.c: fix type comparison for arrays.
1942         * loader.h, loader.c: half-assed fix to get more tests work in cygwin.
1943         Added a couple of new classes to monodefaults.
1944         * icall.c: added a couple of Reflection-related internalcalls.
1945         * class.h, class.c: implemented mono_ldtoken () for RuntimeTypeHandles.
1946         Added a byval_arg MonoType to MonoClass.
1947
1948 2001-09-28  Dick Porter  <dick@ximian.com>
1949
1950         * icall.c:
1951         * threads-pthread.h: 
1952         * threads-pthread.c: Implemented internal calls for
1953         LocalDataStoreSlot operations.  Applied mutexes around all shared
1954         data.  Reworked the thread creation and Start() operations to
1955         avoid a race condition.
1956         
1957         * threads-dummy.h:
1958         * threads-dummy.c: Dummy calls for the LocalDataStoreSlot operations
1959
1960 Thu Sep 27 21:45:55 CEST 2001 Paolo Molaro <lupus@ximian.com>
1961
1962         * rawbuffer.c: disable mmap on cygwin since it seems to be broken there.
1963
1964 Thu Sep 27 19:52:11 CEST 2001 Paolo Molaro <lupus@ximian.com>
1965
1966         * class.c, loader.c: warn and return NULL instead of erroring out.
1967         * icall.c: added System.AppDomain::getCurDomain().
1968         * loader.c: we don't need to lookup the typedef again for p/invoke calls.
1969
1970 2001-09-25  Dick Porter  <dick@ximian.com>
1971
1972         * threads-pthread.h:
1973         * threads-pthread.c: Implemented timed thread joining and added
1974         System.Threading.Thread::Join_internal internal call
1975
1976         * icall.c: Added System.Threading.Thread::Join_internal internal call
1977
1978         * threads-dummy.h:
1979         * threads-dummy.c: Dummy calls for System.Thread.Thread::Join_internal
1980
1981 Mon Sep 24 18:56:59 CEST 2001 Paolo Molaro <lupus@ximian.com>
1982
1983         * object.c, object.h: added mono_ldstr (), mono_string_is_interned () and
1984         mono_string_intern () to implement the semantics of the ldstr opcode
1985         and the interning of System.Strings.
1986         * icall.c: provide hooks to make String::IsIntern and String::Intern
1987         internalcalls.
1988
1989 2001-09-23  Dick Porter  <dick@ximian.com>
1990
1991         * threads-dummy.c: 
1992         * threads-dummy.h: New files of dummy threading routines
1993
1994         * Makefile.am (THREAD_SOURCE): Arrange to compile different thread
1995         support code based on system specifics
1996
1997         Rename PTHREAD_LIBS to THREAD_LIBS
1998         
1999 2001-09-23  Dick Porter  <dick@ximian.com>
2000
2001         * threads-pthread.c: Implement the System.Threading.Thread::Sleep,
2002         Schedule (called when asked to Sleep for 0 ms) and CurrentThread
2003         internal calls.
2004         (mono_thread_init): Set up a Thread object instance to return when
2005         the main thread calls Thread.CurrentThread
2006         (mono_thread_cleanup): Wait for all subthreads to exit
2007
2008         * icall.c: New internal calls for System.Threading.Thread::Sleep
2009         (including Schedule) and CurrentThread
2010
2011         * threads.h: New file, to insulate thread-specific stuff from the
2012         rest of the code
2013
2014 2001-09-21  Dick Porter  <dick@ximian.com>
2015
2016         * threads-pthread.h: 
2017         * threads-pthread.c: New file, for handling pthreads-style
2018         threading support.  Start() now starts a new thread and executes
2019         the ThreadStart delegate instance.
2020
2021         * icall.c: Added the internalcall for
2022         System.Threading.Thread::Start_internal
2023
2024         * Makefile.am: Added new files, and PTHREADS_LIBS to the link line
2025
2026 Thu Sep 20 19:37:39 CEST 2001 Paolo Molaro <lupus@ximian.com>
2027
2028         * loader.c: work around the different signatures for delegates
2029         constructors csc generates in compiled code vs the ones compiled in mscorlib.
2030
2031 Tue Sep 18 13:16:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
2032
2033         * class.h, class.c: add mono_class_get_field_from_name ().
2034         * *: Fix C comments and other ANSI C issues.
2035
2036 Mon Sep 10 20:21:34 CEST 2001 Paolo Molaro <lupus@ximian.com>
2037
2038         * endian.h, assembly.c: fix some endianness issues.
2039
2040 Fri Sep 7 18:40:40 CEST 2001 Paolo Molaro <lupus@ximian.com>
2041
2042         * loader.h, load.c: add delegate_class to mono_defaults.
2043         Handle runtime provided methods in mono_get_method ().
2044
2045 2001-08-29  Dietmar Maurer  <dietmar@ximian.com>
2046
2047         * loader.c (mono_get_method): use pinvoke for internal call
2048
2049         * icall.c: use pinvoke for internal call
2050
2051         * loader.c (method_from_memberref): set the method name
2052
2053 Wed Aug 29 12:43:41 CEST 2001 Paolo Molaro <lupus@ximian.com>
2054
2055         * metadata.c: help the compiler generate better code for
2056         mono_class_from_mono_type ().
2057
2058 2001-08-28  Dietmar Maurer  <dietmar@ximian.com>
2059
2060         * class.c (mono_class_metadata_init): delayed computing of the
2061         class size to mono_class_metadata_init ()
2062
2063 Tue Aug 28 15:47:15 CEST 2001 Paolo Molaro <lupus@ximian.com>
2064
2065         * class.c, class.h: add an interfaces member to MonoClass.
2066         * image.c, image.h: add assembly_name field to MonoImage
2067         from the assembly table.
2068         * metadata.c, metadata.h: add mono_metadata_interfaces_from_typedef ().
2069
2070 Mon Aug 27 20:12:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
2071
2072         * class.c: Handle Array in mono_class_from_mono_type ().
2073         * metadata.c, pedump.c: some endian fixes.
2074
2075 Mon Aug 27 15:23:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
2076
2077         * class.c, loader.c, loader.h: More types handled in mono_class_from_mono_type ().
2078         * metadata.c: fix small problem introduced with the latest commit.
2079
2080 Mon Aug 27 12:17:17 CEST 2001 Paolo Molaro <lupus@ximian.com>
2081
2082         * loader.c, metadata.c, metadata.h: Export mono_metadata_type_equal().
2083         We don't need a MonoMetadata pointer anymore to compare signatures in
2084         mono_metadata_signature_equal (), update callers.
2085         Reduced memory usage an number of allocations for MonoMethodHeader and
2086         MonoMethodSignature.
2087
2088 Sun Aug 26 23:03:09 CEST 2001 Paolo Molaro <lupus@ximian.com>
2089
2090         * metadata.c: added compare for szarray.
2091
2092 Sun Aug 26 11:34:24 CEST 2001 Paolo Molaro <lupus@ximian.com>
2093
2094         * class.h, class.c, loader.h, loader.c: export mono_class_from_mono_type ()
2095         and add a couple more types to it and mono_defaults. Give an hint on
2096         classes that need implementing in our corlib and are referenced
2097         in mscorlib.
2098
2099 Sat Aug 25 12:52:54 CEST 2001 Paolo Molaro <lupus@ximian.com>
2100
2101         * class.h, class.c: keep track if a class is also an Enum.
2102         * loader.c: Implement a couple more types for use in libffi
2103         marshalling. Gives better diagnostics when failing to dlopen
2104         a library. Set method->klass for P/Invoke methods, too.
2105
2106 Fri Aug 24 19:30:25 CEST 2001 Paolo Molaro <lupus@ximian.com>
2107
2108         * class.c, class.h: add a MonoType this_arg to MonoClass that
2109         represents a pointer to an object of the class' type that
2110         can be used by the interpreter and later the type cache.
2111         Add best guess alignment info for valuetype objects.
2112
2113 Fri Aug 24 15:50:31 CEST 2001 Paolo Molaro <lupus@ximian.com>
2114
2115         * metadata.h, metadata.c, class.h, class.c: squeezed MonoParam
2116         into MonoType: one less level of indirection and allocation and
2117         simplifies quite a bit of code. Added cache for MonoTypes that are
2118         used frequently, so that we don't need to allocate them all the time.
2119
2120 2001-08-24  Dietmar Maurer  <dietmar@ximian.com>
2121
2122         * class.c (mono_class_create_from_typedef): System.Enum is also a
2123         value type, although it does not derive from System.ValueType
2124         (maybe a bug in the ms compiler?)
2125
2126         * metadata.c (mono_type_size): return the right size for value types
2127
2128         * loader.c (mono_get_method): only initialize method header if not abstract
2129
2130         * class.c (mono_class_from_mono_type): use mono_default values. 
2131
2132 2001-08-23  Dietmar Maurer  <dietmar@ximian.com>
2133
2134         * *: use MonoClass pointers instead of <type_tokens>
2135         
2136         * class.h: new flag: metadata_inited.
2137
2138         * class.c (mono_class_metadata_init): impl.
2139         (mono_class_instance_size): impl.
2140         (mono_class_data_size): impl.
2141
2142 Wed Aug 22 16:27:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
2143
2144         * metadata.c, loader.h, loader.c, image.h, image.c, class.h, class.c:
2145         MonoClass now has the name and name_space fields. 
2146         MonoMethod has a pointer to its MonoClass, instead of MonoImage.
2147         mono_get_method () takes and optional MonoClass as argument.
2148         Removed mono_typedef_from_name() and added mono_class_token_from_name()
2149         instead that takes advantage of a map from class names to typedef
2150         tokens in MonoImage.
2151
2152 Tue Aug 21 18:54:58 CEST 2001 Paolo Molaro <lupus@ximian.com>
2153
2154         * metadata.c: zero is not a valid alignment boundary.
2155         Merge MONO_TYPE_VOID in default decoding code.
2156
2157 2001-08-21  Dietmar Maurer  <dietmar@ximian.com>
2158
2159         * image.h: merged MonoMetadata into MonoImage
2160
2161         * class.h: cleanup of MonoArrayClass, use a MonoClass pointer to
2162         identify the type of elements.
2163
2164 Mon Aug 20 19:39:00 CEST 2001 Paolo Molaro <lupus@ximian.com>
2165
2166         * blob.h: fix MONO_TYPE_TYPEDBYREF value.
2167         * cil-coff.h: split MonoMSDOSHeader and add size info.
2168         * image.c: add some consistency checks.
2169         * metadata.c: fix row size computation: one programmer
2170         error and one LAMESPEC. Handle MONO_TYPE_TYPEDBYREF.
2171         add explanation for the locator routine.
2172         Fix decoding of size in method header.
2173         
2174 2001-08-20  Miguel de Icaza  <miguel@ximian.com>
2175
2176         * assembly.c    (g_concat_dir_and_file): Use _S for string concat.
2177         (g_concat_dir_and_file): Bring g_concat_dir_and_file
2178         function from gnome-libs.  This uses the right path separator
2179         based on the OS, and also works around a bug in some systems where
2180         a double slash is not allowed. 
2181         (default_assembly_name_resolver): Use g_concat_dir_and_file
2182         (mono_assembly_open): ditto.
2183
2184 2001-08-20  Dietmar Maurer  <dietmar@ximian.com>
2185
2186         * metadata.c (mono_metadata_signature_equal): impl.
2187
2188         * *: void is now a realy MonoType (instead of using NULL)
2189         
2190         * metadata.c (do_mono_metadata_parse_type): use
2191         mono_metadata_parse_type to parse void value.
2192
2193 Sat Aug 18 12:51:28 CEST 2001 Paolo Molaro <lupus@ximian.com>
2194
2195         * metadata.c, metadata.h: in the signature and method header store
2196         only the space required for holding the loca vars and incoming arguments.
2197
2198 2001-08-15  Dietmar Maurer  <dietmar@ximian.com>
2199
2200         * metadata.c (do_mono_metadata_parse_type): treat void like any
2201         other type (instead of assigning NULL);
2202
2203 2001-08-14  Dietmar Maurer  <dietmar@ximian.com>
2204
2205         * metadata.c (mono_metadata_parse_mh): fixxed pinned/byref value
2206
2207 2001-08-09  Dietmar Maurer  <dietmar@ximian.com>
2208
2209         * image.c (do_mono_image_open): added a cache for arrays.
2210
2211 Sat Aug 4 12:46:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
2212
2213         * metadata.h, metadata.c: add mono_metadata_decode_row_col () to
2214         decode a single column from a row in a metadata table and changes
2215         to take advantage of it in the typedef locator (gives a nice speed up).
2216         Store offset info for function params.
2217
2218 2001-08-02  Dietmar Maurer  <dietmar@ximian.com>
2219
2220         * image.h (MONO_IMAGE_IS_CORLIB): removed 
2221
2222 Wed Aug 1 22:54:08 CEST 2001 Paolo Molaro <lupus@ximian.com>
2223
2224         * assembly.c: how could mono_assembly_close () had ever worked?
2225         * metadata.c, metadata.h: provide offset info for local vars.
2226         Implement mono_type_size () to take care of alignment as well
2227         as size (it was mono_field_type_size in cli/class.c before).
2228
2229 2001-08-01  Dietmar Maurer  <dietmar@ximian.com>
2230
2231         * image.h (MONO_IMAGE_IS_CORLIB): new macro to check root image
2232
2233         * assembly.h (CORLIB_NAME): set to corlib.dll
2234
2235         * assembly.c (mono_assembly_open): replaced strcmp() with !strcmp()
2236
2237 Tue Jul 31 17:54:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
2238
2239         * metadata.h, metadata.c, Makefile.am, private.h, assembly.c, blob.h,
2240         cil-coff.h, image.c, image.h, pedump.c, rawbuffer.c, rawbuffer.h, row-indexes.h,
2241         tokentype.h: massive namespace cleanup.
2242
2243 Mon Jul 30 20:11:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
2244
2245         * metadata.h, metadata.c: decode exception clauses when parsing method header.
2246
2247 2001-07-27  Dietmar Maurer  <dietmar@ximian.com>
2248
2249         * metadata.c (mono_metadata_free_type): added check for type !=
2250         NULL (void) before calling mono_metadata_free_type()
2251
2252 Thu Jul 26 19:11:19 CEST 2001 Paolo Molaro <lupus@ximian.com>
2253
2254         * metadata.h, row_indexes.h: added header with enumerations to use
2255         to index in the columns from tables in metadata and to decode coded
2256         tokens: we should start using this instead of embedding magic numbers
2257         all over the code.
2258
2259 Thu Jul 26 13:03:27 CEST 2001 Paolo Molaro <lupus@ximian.com>
2260
2261         * assembly.c, cil-coff.h, image.c, image.h, pedump.c, typedef.c:
2262         Move metadata_t info from cli_image_info_t to MonoImage, where
2263         it's easily accessible. Changed all the uses accordingly.
2264         Added the method and class caches to MonoImage.
2265         * metadata.c, metadata.h: Changed mono_metadata_decode_blob_size ()
2266         and mono_metadata_decode_value () signature to be more consistent
2267         with the other parse functions (and simplify code). Taken advantage
2268         of zero-length array allocation with GCC. Removed reduntant (and
2269         wrong) MonoFieldType struct and use MonoParam instead. Changed
2270         mono_metadata_parse_field_type () to use common code for parsing.
2271         Added mono_metadata_typedef_from_field () and
2272         mono_metadata_typedef_from_method () to lookup a typedef index from a
2273         field or method token.
2274         Pack the MonoRetType structure more tightly (fits in 8 bytes now).
2275
2276 2001-07-23  Miguel de Icaza  <miguel@ximian.com>
2277
2278         * metadata.c (mono_metadata_parse_field_type): Implement. 
2279         (do_mono_metadata_parse_type): Split engine from
2280         mono_metadata_parse_type, so that we can create smaller structures
2281         for things that just have one pointer to the MonoType (look at
2282         the MonoFieldType)
2283
2284 2001-07-20  Miguel de Icaza  <miguel@ximian.com>
2285
2286         * metadata.c (mono_metadata_parse_mh): Correct the implementation,
2287         as Jan Gray found out, it is incorrect. 
2288
2289 2001-07-18  Miguel de Icaza  <miguel@ximian.com>
2290
2291         * assembly.c: Implement asssembly loading.  This loads an image
2292         and loads all the referenced assemblies.  Come to think of it, we
2293         could always do lazy loading of the assemblies. 
2294
2295         * image.c (mono_image_open): Keep loaded images in a hashtable.
2296
2297         * image.h (MonoImage): Add reference count.
2298
2299 2001-07-17  Miguel de Icaza  <miguel@ximian.com>
2300
2301         * assembly.c (mono_assembly_open): Keep track of the file name in
2302         case the assembly has no ASSEMBLY table.
2303
2304         * metadata.h: Fixed Paolo's quick hack.  Put the documnentation
2305         from get.c here.
2306
2307 Sun Jul 15 19:39:06 CEST 2001 Paolo Molaro <lupus@ximian.com>
2308
2309         * metadata.c, metadata.h: decode local vars in method header
2310         parse function. Change callers accordingly.
2311
2312 Sun Jul 15 17:40:47 CEST 2001 Paolo Molaro <lupus@ximian.com>
2313
2314         * metadata.h, cil-coff.h: protect against multiple inclusion.
2315         Added some new structures to hold information decoded from metadata:
2316         MonoType, MonoParam, MonoArray, MonoMethod, MonoMethodSignature
2317         and relevant decoding/free functions.
2318         * metadata.c: implement decoding functions. Add warning for out of bounds
2319         index in mono_metadata_locate(). Implement mono_get_method () to retreive
2320         all the info about a method signature and invocation. Remove check on
2321         uninitialized local var in parse_mh() and fix memory leak.
2322
2323 2001-07-12  Miguel de Icaza  <miguel@ximian.com>
2324
2325         * metadata.h: More macros.
2326
2327         * tokentype.h: New file.
2328
2329 Fri Jul  6 11:30:53 CEST 2001 Paolo Molaro <lupus@ximian.com>
2330
2331         * assembly.c: added a consistency check and initialize
2332         some structures with g_new0().
2333         * metadata.c: fixed a couple more bugs in table size computation
2334         and add other checks for out-of bound access to metadata.
2335
2336 Thu Jul  5 22:34:21 CEST 2001 Paolo Molaro <lupus@ximian.com>
2337
2338         * metatada.c: fix bugs computing table sizes. Spew a
2339         warning when index in string heap is out of bounds.
2340
2341 2001-07-04  Miguel de Icaza  <miguel@ximian.com>
2342
2343         * metadata.h: Add a couple of macros to manipulate tokens. 
2344
2345 Tue Jul  3 18:33:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
2346
2347         * assembly.c: g_free(ii->cli_sections) (and avoid double free of
2348         cli_section_tables).
2349
2350 2001-07-01  Miguel de Icaza  <miguel@ximian.com>
2351
2352         * metadata.c (mono_metadata_user_string): New function, provides
2353         access to the UserString heap. 
2354
2355 2001-06-27  Miguel de Icaza  <miguel@ximian.com>
2356
2357         * metadata.c: Add inline documentation.
2358
2359 2001-06-26  Miguel de Icaza  <miguel@ximian.com>
2360
2361         * propertyattr.h, paramattr.h, methodsem.h, methodattr.h: New
2362         files. 
2363
2364 2001-06-22  Miguel de Icaza  <miguel@ximian.com>
2365
2366         * typeattr.h: New file, TypeAttribute flags. 
2367
2368 2001-06-21  Miguel de Icaza  <miguel@ximian.com>
2369
2370         * mono/metadata/assembly.c (mono_assembly_ensure_section_idx,
2371         mono_assembly_ensure_section): Section loading code.
2372         (load_section_tables): Load the sections.
2373
2374         * mono/metadata/metadata.c (mono_metadata_locate_token,
2375         mono_metadata_locate): Functions to locate the information
2376         definition given a token or a table and an index.
2377         (mono_metadata_compute_table_bases): New.
2378         (compute_size): New function to compute the sizes of the various
2379         tables.
2380
2381         * mono/metadata/metadata.h: Finish listing the different index
2382         types. 
2383
2384         * mono/metadata/pedump.c: Improve to dump new information.
2385
2386 2001-06-19  Miguel de Icaza  <miguel@ximian.com>
2387
2388         * mono/metadata/metadata.c: Entered all the tables matching
2389         Beta2. 
2390
2391         * mono/metadata/assembly.c (load_metadata_ptrs): Fix for Beta2
2392