98522bf359d9b67880ef5ecca1e6ca35e2a46045
[mono.git] / mono / metadata / ChangeLog
1 2004-05-14  Zoltan Varga  <vargaz@freemail.hu>
2
3         * icall.c (ves_icall_System_Reflection_Assembly_load_with_partial_name): Fix warning.
4
5         * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
6
7         * icall.c: Optimize Buffer.BlockCopy.
8
9 2004-05-14  Gonzalo Paniagua Javier <gonzalo@ximian.com>
10
11         * culture-info-tables.h: seems like Spanish and Portuguese cultures had
12         DateTimeFormatInfo.YearMonthPattern like "MMMM' yyyy" (note the single
13         quote). Changed them to "MMMM yyyy".
14
15 2004-05-12  Miguel de Icaza  <miguel@ximian.com>
16
17         * rand.c
18         (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_InternalGetBytes): Always close the file. 
19
20 2004-05-13  Zoltan Varga  <vargaz@freemail.hu>
21
22         * reflection.h: Updated after changes to managed structures.
23
24         * appdomain.c: Bump corlib version.
25
26 2004-05-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
27
28         * Makefile.am: also add libmonoos to libmetadata. Fixes the build on
29         windows.
30
31 2004-05-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
32
33         * Makefile.am: link to ../os/libmonoos.la on windows.
34
35         * assembly.c:
36                 -If MONO_DEBUG, warn about non-existing directories in
37                 MONO_PATH.
38                 -Added mono_assembly_getrootdir() that replaces MONO_ASSEMBLIES
39                 compile time variable.
40                 -Removed init_default_path and call mono_set_rootdir from
41                 libmonoos.a instead (windows only).
42
43         * assembly.h: declare mono_assembly_getrootdir().
44
45         * domain.c:
46         * icall.c: use mono_assembly_getrootdir() instead of MONO_ASSEMBLIES.
47
48         * loader.c: s/getenv/g_getenv/
49
50 2004-05-11  Zoltan Varga  <vargaz@freemail.hu>
51
52         * marshal.{h,c}: Add support for UnmanagedType.AsAny.
53
54         * marshal.c: Use mono_metadata_signature_{alloc,dup} where appropriate.
55
56         * metadata.h: Add new marshalling conversions.
57
58         * metadata.h metadata.c (mono_metadata_signature_dup): New helper
59         function.
60
61         * reflection.c (mono_reflection_get_type): Lookup the type in all
62         modules of a multi-module assembly. Fixes #58291.
63
64 2004-05-11  Lluis Sanchez Gual  <lluis@ximian.com>
65
66         * threads.c: Before aborting a background, set the StopRequested
67         state.  This avoids throwing the Abort exception.
68         In mono_thread_manage, don't continue with the shutdown until all
69         aborted threads have actually stopped.
70
71 2004-05-10  Jackson Harper  <jackson@ximian.com>
72
73         * locales.c: Remove the modifier from culture names.
74         
75 2004-05-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
76
77         * Makefile.am: monosn is not installed any more. It has been deprecated
78         in favor of sn.
79
80 2004-05-07  Jackson Harper  <jackson@ximian.com>
81
82         * locales.c
83         (ves_icall_System_Globalization_CultureInfo_internal_get_cultures):
84         Fix array construction, add bailout if the length is 0.
85
86 2004-05-07  Dick Porter  <dick@ximian.com>
87
88         * socket-io.c (addrinfo_to_IPHostEntry): Don't crash if the
89         machine doesn't have a DNS entry.  Patch by Urs Muff
90         (umuff@quark.com), fixes bug 57928.
91
92 2004-05-06  Jackson Harper  <jackson@ximian.com>
93
94         * reflection.c: Handle null PublicTokens properly. alloc mem for
95         assembly names culture so we dont crash when freeing it.
96         
97 2004-05-06  Jackson Harper  <jackson@ximian.com>
98
99         * assembly.c: Check the usergac when loading with partial names.
100         
101 2004-05-05  Sebastien Pouliot  <sebastien@ximian.com>
102
103         * rand.c|h: Added new icall for (optionally) seeding the PRNG. This 
104         does nothing for now (not required for Linux/Windows) but the class
105         library can call it (and a newer or modified runtime could need it).
106         * icall.c: Registred icall.
107
108 2004-05-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
109
110         * loader.c: prints a message on module loading error we set MONO_DEBUG
111         environment variable.
112
113 2004-05-05  Jackson Harper  <jackson@ximian.com>
114
115         * appdomain.c: Handle PublicKeyToken=null properly.
116         
117 2004-05-05  Sebastien Pouliot  <sebastien@ximian.com>
118
119         * environment.c|h: Added icall ves_icall_System_Environment_
120         GetOSVersionString to get the current OS version as a string.
121         * icall.c: Registred icall.
122
123 2004-05-05  Lluis Sanchez Gual  <lluis@ximian.com>
124
125         * object.c: in mono_object_get_virtual_method(), take into account that
126         non-virtual methods don't have a slot in the vtable. Check needed when
127         the object is a proxy.
128
129 2004-05-05  Zoltan Varga  <vargaz@freemail.hu>
130
131         * marshal.h marshal.c icall.c: Applied patch from vladimir@pobox.com
132         (Vladimir Vukicevic). Implement UnsafeAddrOfPinnedArrayElement.
133
134         * object.c (mono_class_compute_gc_descriptor): Fix warning.
135
136         * object.c (mono_runtime_invoke_array): Add an assert so null cannot be
137         passed when a valuetype is expected.
138
139         * object.c (mono_unhandled_exception): Only set the exit code if the
140         exception happens in the main thread. Fixes thread5.exe.
141
142         * appdomain.c (get_info_from_assembly_name): Fix infinite loop on
143         invalid names. Fixes #58047.
144
145 2004-05-03  Jackson Harper  <jackson@ximian.com>
146
147         * assembly.c: This line was committed accidently and is unneeded.
148         
149 2004-05-03  Jackson Harper  <jackson@ximian.com>
150
151         * icall.c: Add new icall for Assembly::LoadWithPartialName
152         * assembly.c/.h: new function that probes the GAC to load partial
153         assembly names by Paolo Molaro.
154         
155 2004-05-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
156
157         * appdomain.c: use g_strncasecmp when looking for 'Culture=' et al.
158         * reflection.c: use g_strncasecmp when looking for 'Culture=' et al.
159         (type_get_fully_qualified_name): Added PublicKeyToken when building a
160         full type name.
161
162 2004-05-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
163
164         * appdomain.c: fixed check for 'neutral' culture and removed warning.
165         * reflection.c: fix bug when parsing a full type name and Version is not
166         the last thing in the string.
167
168 2004-05-03  Zoltan Varga  <vargaz@freemail.hu>
169
170         * appdomain.c (get_info_from_assembly_name): Strdup "" to prevent
171         crashes when it is freed.
172
173 2004-05-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
174
175         * assembly.c: print the compat warning to stderr.
176
177 2004-05-01  Miguel de Icaza  <miguel@ximian.com>
178
179         * assembly.c (mono_assembly_load_references): Add a compatibility
180         hack to run old applications that might be still referencing the
181         3300-based assemblies, only do this for System.xxx.
182
183 2004-05-01  Jackson Harper  <jackson@ximian.com>
184
185         * appdomain.c: If the culture is neutral we set it to "".
186         
187 2004-04-29  Jackson Harper  <jackson@ximian.com>
188
189         * locales.c: Add some missing MONO_ARCH_SAVE_REGS'.
190
191 2004-04-29  Andreas Nahr <ClassDevelopment@A-SoftTech.com>
192  
193         * string-icalls.c: added low overhead function for copying chars
194         * icall.c: added needed icall for the above function
195  
196 2004-04-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
197
198         * icall.c: fix return value of get_global_assembly_cache.  Implemented
199         Environment.GetLogicalDrives.
200
201 2004-04-28  Bernie Solomon  <bernard@ugsolutions.com>
202
203         * rand.c: try and talk to egd or prngd
204         for random bytes if opening devices fail.
205
206 2004-04-28  Zoltan Varga  <vargaz@freemail.hu>
207
208         * marshal.c (mono_marshal_load_type_info): Calculate the minimum
209         alignment for the type using the native alignment of its members 
210         instead of using klass->min_align.
211
212         * metadata.c (mono_type_stack_size): Fix size of TYPEDBYREF.
213
214 2004-04-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
215
216         * file-io.c:
217         * socket-io.c: added check for sys/aio.h.
218
219 2004-04-28  Dick Porter  <dick@ximian.com>
220
221         * threads.c: Don't abort a thread thats already aborting, when
222         terminating everything.
223
224 2004-04-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
225
226         * icall.c: added 2 new async calls for Socket.
227
228         * socket-io.[ch]: fixed some warnings. Added support for asynchronous
229         IO on *nix systems.
230
231         * threadpool.c: removed unused variable.
232
233 2004-04-27  Zoltan Varga  <vargaz@freemail.hu>
234
235         * marshal.c: Handle null properly in PtrToString* icalls. Fixes #57706.
236
237 Tue Apr 27 15:55:17 CEST 2004 Paolo Molaro <lupus@ximian.com>
238
239         * locales.c: put back string_invariant_tolower () and
240         string_invariant_toupper ().
241
242 2004-04-26 David Waite <mass@akuma.org>
243
244         * file-io.h:
245         * socket-io.h:
246         * threads.h:
247         * unicode.h: remove comma from end of enumeration declarations
248
249 2004-04-26 David Waite <mass@akuma.org>
250
251         * debug-mono-symfile.h:
252         * decimal.c:
253         * mono_debug.h:
254         * sysmath.c: Define 64 bit constants as long long types (i.e. 10ULL)
255
256
257 2004-04-26  Jackson Harper  <jackson@ximian.com>
258
259         * appdomain.c: Increment version number.
260         
261 2004-04-26  Jackson Harper  <jackson@ximian.com>
262
263         * appdomain.c: Set assembly references public token value when
264         PublicKeyToken is specified, not the hash_value. Free public token
265         values when free assembly name data. Previously the public key
266         token was hex decoded, however we are using hex encoded public key
267         tokens, so this is not neccasary.
268         * assembly.c: Lookup assemblies in the gac if their public token
269         value is set. Add function to allow enabling user gac
270         lookups. Specify whether or not the assembly was loaded from the
271         GAC. Compare full assembly names when checking the cache for
272         assemblies (Temporarily disabled see comment in code). Remove
273         mscorlib -> corlib mapping cruft. Add trace-loading. When a user
274         specifies trace-loader they get extra info to stdout on the
275         loading of assemblies.
276         * image.h: Add a field for an assembly references public token
277         value to MonoAssemblyname. Add a field to MonoAssembly to specifiy
278         whether an assembly has been loaded from the GAC.
279         * image.c: Remove a corlib -> mscorlib name mapping.
280         * loader.h: Add function to enable/disable the user gac.
281         * mono-config.c: Check if the usergac is enabled in the config
282         file.
283         * icall.c: New icall to determine whether or not an assembly has
284         been loaded from the GAC. Remove some mscorlib -> corlib mappings.
285         * tabldefs.h: Add constant for assemblyref flag that specifies a
286         full public key is used instead of a public token.
287         * reflection.c: Remove mscorlib -> corlib mappings. Set
288         PublicTokenValue instead of hash value. This value is a hex
289         string so it does not need to be expanded.
290
291 2004-04-26  Martin Baulig  <martin@ximian.com>
292
293         * mono-debug-debugger.c (mono_debugger_initialize): Set
294         `mono_debugger_initialized' before calling mono_debug_lock().
295
296 2004-04-42  Robert Shade <rshade@dvsconsulting.com>
297
298         * icall.c: icalls for Char.ToUpper/ToLower are now hooked to
299           InternalToUpper/InternalToLower.
300         * locales.c: (ves_icall_System_{Char,String}_InternalTo{Upper,Lower}_Comp)
301           removed invariant culture shortcut.  This is now done in managed code.
302         * locales.c: (string_invariant_toupper/tolower) removed.
303
304 2004-04-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
305
306         * icall.c: added GetSupportsAsync for Socket (same as MonoIO).
307         Added Poll internal call.
308
309         * socket-io.[ch]: _wapi_socket == WSASocket. Added internal
310         call for Poll. Select was too heavy for polling a single socket.
311
312         * threadpool.[ch]: added mono_threadpool_cleanup.
313         * threads.c: use it. Don't use Thread_Abort on windows.
314
315 2004-04-23  Martin Baulig  <martin@ximian.com>
316
317         * mono-debug-debugger.c (mono_debugger_lookup_assembly): New function.
318
319 2004-04-23  Sebastien Pouliot  <sebastien@ximian.com>
320
321         * icall.c: Registred new icalls for key pair protection and added an
322         icall for Environment.GetFolderPath on Windows.
323         * security.c|h: Added new icalls for key pair protection.
324
325 2004-04-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
326
327         * socket-io.c: don't display the non-supported family warning for known
328         families. Now this is not displayed on windows when checking support
329         for IPv4/IPv6.
330
331 2004-04-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
332
333         * class.c: don't display the layout warning for static fields.
334
335 2004-04-21  Lluis Sanchez Gual <lluis@ximian.com>
336
337         * icall.cs: Registered new icalls for Char.ToLower and Char.ToUpper.
338         * locales.c, locales.h: Added new icalls for culture-specific
339         Char.ToLower and Char.ToUpper.
340
341 2004-04-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
342
343         * threads.c: the 2nd argument when aborting a thread is NULL now. Patch
344         by David Waite.
345
346 2004-04-20  Martin Baulig  <martin@ximian.com>
347
348         * mono-debug-debugger.c (mono_debugger_lookup_type): Make a copy
349         of the type name before passing it to mono_reflection_type_from_name().
350
351 2004-04-19  Zoltan Varga  <vargaz@freemail.hu>
352
353         * marshal.c (mono_marshal_get_managed_wrapper): Handle different string
354         encodings here. Fixes #56965.
355
356 2004-04-18  Bernie Solomon <bernard@ugsolutions.com>
357
358         * icall.c (ves_icall_System_Text_Encoding_InternalCodePage):
359         fix test on strstr result not that I can see anything that
360         relies on the result.
361
362 2004-04-18  Zoltan Varga  <vargaz@freemail.hu>
363
364         * metadata.c (mono_type_to_unmanaged): Handle MONO_NATIVE_FUNC as well.
365         Fixes #57081.
366
367         * marshal.c (mono_marshal_get_string_encoding): New helper function.
368
369         * marshal.c (mono_marshal_get_native_wrapper): Use the new helper
370         function to determine which marshalling to use for strings. Fixes
371         #56965.
372
373         * marshal.c (mono_marshal_string_array_to_unicode): Fix warning.
374
375         * reflection.c (encode_marshal_blob): Add support for LPARRAY.
376
377 2004-04-15  Bernie Solomon  <bernard@ugsolutions.com>
378
379         * icall.c: #include mono-config.h
380
381 2004-04-15  Jackson Harper  <jackson@ximian.com>
382
383         * culture-info-tables.h: Fix date formats for en-US culture.
384         
385 2004-04-15  Lluis Sanchez Gual  <lluis@ximian.com>
386
387         * icall.c: Registered icalls for ThreadPool.GetMinThreads and 
388         ThreadPool.SetMinThreads.
389         * threadpool.c: Implemented ThreadPool.GetMinThreads and
390         ThreadPool.SetMinThreads.
391
392 Thu Apr 15 15:36:40 CEST 2004 Paolo Molaro <lupus@ximian.com>
393
394         * mono-config.c: also load the .config file in the directory
395         where the assembly was found.
396
397 Thu Apr 15 14:24:49 CEST 2004 Paolo Molaro <lupus@ximian.com>
398
399         * assembly.c: load per-assembly config files.
400         * icall.c: decrapified code to get the config dir and moved to
401         mono-config.c.
402         * image.h, loader.c, loader.h, mono-config.c, mono-config.h: allow
403         per-assembly config files. When doing a dll map lookup give precedence
404         to the per-assembly data.
405
406 2004-04-14  Martin Baulig  <martin@ximian.com>
407
408         * mono-debug-debugger.h (MonoDebuggerEvent): Removed
409         MONO_DEBUGGER_EVENT_TYPE_ADDED and MONO_DEBUGGER_EVENT_METHOD_ADDED
410         and added MONO_DEBUGGER_EVENT_RELOAD_SYMTABS.
411
412         * mono-debugger-debugger.c: While the debugger is locked, remember
413         whether the symbol tables have changes and send one single
414         MONO_DEBUGGER_EVENT_RELOAD_SYMTABS when releasing the lock.
415
416 2004-04-14  Zoltan Varga  <vargaz@freemail.hu>
417
418         * metadata.h: Add STRARRAY_STRWLPARRAY marshalling convention.
419
420         * marshal.h marshal.c (mono_marshal_string_array_to_unicode): New 
421         function.
422
423         * marshal.c (mono_marshal_get_native_wrapper): Take CharSet into
424         account when marshalling string arrays. Fixes #56965.
425
426 2004-04-13  Sebastien Pouliot  <sebastien@ximian.com>
427
428         * icall.c: Add new icalls mapping for security.
429         * security.c|h: Add internal calls for WindowsIdentity,
430         WindowsImpersonationContext and WindowsPrincipal.
431
432 2004-04-13  Gert Driesen (drieseng@users.sourceforge.net)
433
434         * class.c: Added comment to ensure the System.MonoDummy class
435         is removed when no longer necessary
436
437 2004-04-13  Miguel de Icaza  <miguel@ximian.com>
438
439         * appdomain.c: Pass arguments to the bootstraping exceptions to
440         minimize JITed methods at boot
441
442         * metadata.c (mono_exception_from_name_two_strings): Allow for the
443         second string to be null.
444
445         * icall.c (ves_icall_System_Text_Encoding_InternalCodePage):
446         Change the protocol to minimize the JIT methods at startup.  Now
447         it Returns the internal codepage, if the value of "int_code_page"
448         is 1 at entry, and we can not compute a suitable code page
449         number, returns the code page as a string.
450
451 2004-04-13  Jackson Harper  <jackson@ximian.com>
452
453         * culture-info-tables.h: Fix number of decimal digits for all
454         english locales.
455
456 2004-04-13  Jackson Harper  <jackson@ximian.com>
457
458         * icall.c: Clairfy out of sync error message. It is not always
459         your corlib that is out of sync.
460
461 2004-04-13  Zoltan Varga  <vargaz@freemail.hu>
462
463         * icall.c (ves_icall_Type_GetPropertiesByName): Avoid duplicate
464         properties when only the set accessor is overriden. Fixes #55874.
465
466 2004-04-09  Zoltan Varga  <vargaz@freemail.hu>
467
468         * assembly.c (mono_assembly_load_references): Make this thread safe.
469         Fixes #56327.
470
471 2004-04-08  Zoltan Varga  <vargaz@freemail.hu>
472
473         * monosn.c: Add missing initialization calls.
474
475 2004-04-08  Bernie Solomon  <bernard@ugsolutions.com>
476
477         * locales.c:
478         ves_icall_System_Globalization_CultureInfo_construct_number_format
479         Fix g_assert so it compiles on fussier compilers re int/ptr
480         mismatch
481
482 2004-04-08  Dick Porter  <dick@ximian.com>
483
484         * socket-io.h:
485         * socket-io.c: Don't set SO_REUSEADDR on windows.  Fixes bug
486         53992.  Also rearrange the code so that the internal calls return
487         an error value and exceptions are thrown from managed code.
488
489         * icall.c: Add type info to the socket icalls.
490
491 2004-04-08  Gonzalo Paniagua Javier <gonzalo@ximian.com>
492
493         * object.h: synchronize MonoCompareInfo with CompareInfo class. Someone
494         owes me a beer.
495
496 2004-04-07  Martin Baulig  <martin@ximian.com>
497
498         * class.c (mono_class_from_generic_parameter): Don't default
499         `klass->parent' to `mono_defaults.object_type'.
500
501 2004-04-07  Martin Baulig  <martin@ximian.com>
502
503         * reflection.c (mono_reflection_initialize_generic_parameter): Set
504         `param->pklass->reflection_info'.       
505
506 2004-04-07  Jackson Harper  <jackson@ximian.com>
507
508         * culture-info-tables.h: Fix date separator symbol.
509         
510 2004-04-07  Martin Baulig  <martin@ximian.com>
511
512         * icall.c (ves_icall_Type_GetGenericArguments): Moved this icall
513         from System.Type to System.MonoType.
514
515 2004-04-07  Martin Baulig  <martin@ximian.com>
516
517         * reflection.h
518         (MonoReflectionGenericParam): Added `has_reference_type' and
519         `has_value_type' fields.
520
521         * reflection.c (mono_image_get_generic_param_info): Encode the
522         correct flags if we have the `class' or `struct' constraint.
523
524 2004-04-07  Martin Baulig  <martin@ximian.com>
525
526         * reflection.h
527         (MonoReflectionGenericParam): Added `MonoBoolean has_ctor_constraint'.
528
529 2004-04-07  Jackson Harper  <jackson@ximian.com>
530
531         * appdomain.c: Revert extra patches, just wanted to bump the
532         version number.
533         
534 2004-04-07  Jackson Harper  <jackson@ximian.com>
535
536         * Makefile.am: Add culture-info private headers.
537         * icall.c: Add new icalls for contructing locales.
538         * locales.c: Construct CultureInfo objects from lookup tables instead of using ICU.
539         * locales.h: Declare new culture info construction methods.
540         * object.h: Add new fields used to avoid the CultureMap to
541         MonoCultureInfo.
542         * culture-info.h: Definition of structs used in the culture info
543         tables.
544         * culture-info-tables.h: Autogenerated tables that contain culture
545         info data. This file was generated with the locale-builder tool.
546         * appdomain.c: Incement corlib version number.
547         
548 2004-04-07  Bernie Solomon  <bernard@ugsolutions.com>
549
550         * appdomain.c: (mono_runtime_init) move mono_thread_init
551         to before mono_object_new calls so critical sections
552         are initialized before use.
553
554 2004-04-07  Martin Baulig  <martin@ximian.com>
555
556         * icall.c
557         (ves_icall_TypeBuilder_define_generic_parameter): Removed.
558         (ves_icall_MethodBuilder_define_generic_parameter): Removed.
559         (ves_icall_MonoGenericParam_initialize): Removed.
560         (monogenericparam_icalls): Removed.
561         (generictypeparambuilder_icalls): Added new table for
562         System.Reflection.Emit.GenericTypeParameterBuilder.
563
564         * reflection.c
565         (mono_reflection_define_generic_parameter): Removed.
566         (mono_reflection_initialize_generic_parameter): This is now called
567         from GenericTypeParameterBuilder's .ctor.
568
569 2004-04-06  Martin Baulig  <martin@ximian.com>
570
571         * class.c (mono_class_init): Don't inflate nested classes in a
572         generic instance.
573         (mono_type_get_name_recurse): Include the generic arguments for
574         generic instances and generic type declarations.
575         (inflate_generic_type): Correctly inflate MONO_TYPE_SZARRAY.
576         (_mono_class_get_instantiation_name): Removed.
577         (mono_class_create_generic): Always use `gklass->name' as our name.
578
579         * class.h (MonoGenericInst): Removed `nested_in', and `nested'.
580
581         * icall.c (ves_icall_MonoGenericInst_GetDeclaringType): Removed.
582         (ves_icall_MonoGenericInst_GetNestedTypes): Removed.
583         (ves_icall_MonoMethod_GetGenericParameters): Renamed to
584         ves_icall_MonoMethod_GetGenericArguments() and correctly handle
585         closed generic methods here.
586
587         * reflection.c
588         (mono_reflection_generic_inst_get_nested_types): Removed.
589         (inflate_mono_method): Copy the generic parameters from the
590         MonoMethodHeader into out MonoGenericMethod.
591
592 2004-04-06  Martin Baulig  <martin@ximian.com>
593
594         * row-indexes.h
595         (MONO_GENERICPARAM_DEPRECATED_CONSTRAINT): Removed.
596
597         * metadata.c (GenericParamSchema): Removed "DeprecatedConstraint".
598
599         * reflection.c (build_compressed_metadata): If we have any entries
600         in the GenericParam, MethodSpec or GenericParamConstraint tables,
601         set the header version to 1.1.
602
603 2004-04-06  Martin Baulig  <martin@ximian.com>
604
605         * class.c (mono_class_init): If we're a generic instance,
606         initialize our nested classes, too.
607         (_mono_class_get_instantiation_name): Deal with the new `!%d'
608         suffix. 
609
610 2004-04-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
611
612         * process.c: quote the argument passed to the shell on windows.
613
614 2004-04-05  Zoltan Varga  <vargaz@freemail.hu>
615
616         * threads.c (mono_alloc_special_static_data): Allow this to be
617         called during startup.
618
619 2004-04-02  Martin Baulig  <martin@ximian.com>
620
621         * icall.c
622         (ves_icall_MonoGenericInst_GetDeclaringType): New icall.
623
624 2004-04-02  Zoltan Varga  <vargaz@freemail.hu>
625
626         * icall.c: Fix build.
627
628 2004-04-02  Sebastien Pouliot  <sebastien@ximian.com>
629
630         * Makefile.am: Added security.c|h.
631         * icall.c: Added icall for get_UserName;
632         * security.c: New file for security related icalls. Added function
633         get_UserName for System.Environment (fix #56144).
634         * security.h: New. Header file for security.c
635
636 2004-04-02  Dick Porter  <dick@ximian.com>
637
638         * icall.c: Deleted the icalls that were obsoleted some time ago
639         by the ICU string code, and which were mixed into the icall
640         rearranging.  Fixes bug 55969.
641
642         * string-icalls.h: 
643         * string-icalls.c: Deleted the code that those icalls reference.
644
645 2004-04-01  Martin Baulig  <martin@ximian.com>
646
647         * metadata.h (MONO_CLASS_IS_INTERFACE): New macro.
648
649         * class.c (mono_class_from_generic_parameter): Don't set 
650         TYPE_ATTRIBUTE_INTERFACE.
651         (my_mono_class_from_generic_parameter): Likewise.
652
653 2004-04-01  Martin Baulig  <martin@ximian.com>
654
655         * loader.c (find_method): Added an optional `MonoClass *ic'
656         argument to search in a specific interface.
657         (mono_get_method_constrained): New public function.
658
659 2004-04-01  Martin Baulig  <martin@ximian.com>
660
661         * reflection.c (mono_image_get_generic_field_token): Use the
662         `handleref' cache here.
663
664 2004-04-01  Martin Baulig  <martin@ximian.com>
665
666         * reflection.h (MonoDynamicImage): Added `GHashTable *typespec'.
667
668         * reflection.c (create_generic_typespec): Use the `typespec' hash
669         here, not the `typeref' one.    
670
671 2004-04-01  Martin Baulig  <martin@ximian.com>
672
673         * class.c (mono_class_inflate_generic_type): Moved the
674         functionality into a new static inflate_generic_type() which
675         returns NULL if it didn't do anything.  Only increment the
676         `mono_stats.inflated_type_count' if we actually inflated
677         something.
678         (mono_class_get_full): Check the classes type to see whether we
679         need to inflate it; also inflate MONO_TYPE_(M)VAR.
680
681 2004-04-01  Jackson Harper  <jackson@ximian.com>
682
683         * reflection.c: Set culture for assembly references.
684         
685 2004-04-01 Ben Maurer  <bmaurer@users.sourceforge.net>
686
687         * reflection.[ch], icall.[ch], Fix support for pinning variables.
688
689 2004-04-01  Gonzalo Paniagua Javier <gonzalo@ximian.com>
690
691         * assembly.c:
692         (do_mono_assembly_open): the critical section also covers
693         mono_image_open and mono_image_open_from_data. Fixes bug #56327.
694
695 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
696
697         * threads.c:
698         (mono_manage_threads): abort the background threads when finishing.
699         Fixes bug #47232.
700
701 2004-03-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
702
703         * gc.c: only close the done_event handle if there was no timeout.
704         C-ified comments.
705
706 2004-03-30  Martin Baulig  <martin@ximian.com>
707
708         * icall.c (icall_entries): It's called "System.Activator", not
709         "System.Activation".    
710
711 2004-03-30  Martin Baulig  <martin@ximian.com>
712
713         * class.c (mono_ldtoken): Added `MonoGenericContext *' argument.
714         (mono_class_create_from_typespec): Likewise.
715
716 2004-03-30  Martin Baulig  <martin@ximian.com>
717
718         * reflection.h (MonoReflectionGenericParam): Use MonoBoolean for
719         `has_ctor_constraint' and `initialized'.
720
721 2004-03-30  Martin Baulig  <martin@ximian.com>
722
723         * reflection.c (encode_new_constraint): New static function to add
724         the constructor constraint attribute to a type parameter.
725         (encode_constraints): Call encode_new_constraint() if necessary.
726
727         * reflection.h
728         (MonoReflectionGenericParam): Added `guint32 has_ctor_constraint'.
729
730         * row-indexes.h: Added CUSTOM_ATTR_GENERICPAR.
731         
732 2004-03-29 Ben Maurer  <bmaurer@users.sourceforge.net>
733
734         * reflection.c, icall.c: add support for pinning variables. 
735
736 2004-03-29  Bernie Solomon  <bernard@ugsolutions.com>
737
738         * marshal.c (mono_marshal_get_managed_wrapper):
739         init bool local with zero rather than null.
740
741 2004-03-29  Martin Baulig  <martin@ximian.com>
742
743         * icall.c (ves_icall_MonoMethod_get_HasGenericParameters): Show
744         the "official" behavior here.
745         (ves_icall_MonoMethod_get_Mono_IsInflatedMethod): New interncall.
746
747 2004-03-29  Martin Baulig  <martin@ximian.com>
748
749         * icall.c: Reflect latest API changes.
750
751 2004-03-29  Martin Baulig  <martin@ximian.com>
752
753         * loader.c (mono_get_method_from_token): Also call
754         mono_metadata_load_generic_params () for abstract and interface
755         methods; replace the type arguments in the method signature with
756         the ones which are loaded from the metadata.
757
758 2004-03-29  Lluis Sanchez Gual  <lluis@ximian.com>
759
760         * monitor.c: In mono_monitor_exit(), don't throw an exception if the owner
761         of the lock is not the current thread. MS.NET don't do it, in spite of
762         what the documentation says. See bug #56157.
763
764 2004-03-28  Martin Baulig  <martin@ximian.com>
765
766         * class.c (mono_class_init): Don't call init_properties() and
767         init_events() for generic instances; set `prop->parent' when
768         inflating properties.
769
770         * reflection.c (mono_generic_inst_get_object): Call
771         `mono_class_init (ginst->klass)'.
772         (mono_type_get_object): Only create a MonoGenericInst if your
773         generic type is a TypeBuilder.
774         (do_mono_reflection_bind_generic_parameters): Only set
775         `ginst->is_dynamic' if our generic type is a TypeBuilder.
776
777 2004-03-28  Zoltan Varga  <vargaz@freemail.hu>
778
779         * appdomain.c (unload_thread_main): Do not clear proxy_vtable_hash.
780         Fixes #56091.
781
782 2004-03-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
783
784         * icall.c: added Kill_internal icall.
785         * process.[ch]: added Kill_internal icall.
786
787 2004-03-25  Martin Baulig  <martin@ximian.com>
788
789         * class.h (MonoStats): Added `generic_instance_count',
790         `inflated_method_count', `inflated_type_count' and
791         `generics_metadata_size'.       
792
793 2004-03-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
794
795         * reflection.c: no warnings now.
796
797 2004-03-25  Martin Baulig  <martin@ximian.com>
798
799         * class.c (mono_class_get_full): New public function; does a
800         mono_class_get(), but also takes a `MonoGenericContext *'.
801
802         * loader.c (mono_field_from_memberref): Renamed to
803         `field_from_memberref', made static and added `MonoGenericContext *'
804         argument.
805         (mono_field_from_token): Added `MonoGenericInst *' argument.
806         (method_from_memberef): Likewise.
807         (mono_get_method_from_token): Likewise.
808         (mono_get_method_full): New public function; does a
809         mono_get_method(), but also takes a `MonoGenericContext *'.
810
811         * verify.c (mono_method_verify): Get the method's generic context
812         and pass it to mono_field_from_token(), mono_get_method_full() and
813         mono_class_get_full().
814
815 2004-03-25  Martin Baulig  <martin@ximian.com>
816
817         * class.c (mono_class_inflate_generic_type): Take a
818         `MonoGenericContext *' instead of a `MonoGenericInst *' and a
819         `MonoGenericMethod *'.
820
821 2004-03-25  Martin Baulig  <martin@ximian.com>
822
823         * loader.h (MonoMethodInflated): Store the MonoGenericContext
824         instead of the MonoGenericMethod here.
825
826 2004-03-25  Martin Baulig  <martin@ximian.com>
827
828         * class.h (MonoGenericInst): Added `MonoGenericContext *context';
829         each time we create a new MonoGenericInst, we also create a new
830         context which points back to us.
831
832         * class.c (inflate_method): Use `ginst->context' instead of
833         creating a new context.
834
835         * loader.c (method_from_memberref): Use
836         `klass->generic_inst->context' instead of creating a new context.
837
838 2004-03-25  Martin Baulig  <martin@ximian.com>
839
840         * class.h (MonoGenericContext): New struct.
841         (MonoGenericMethod): Removed `generic_inst'.
842
843         * class.c (mono_class_inflate_generic_method): Take a
844         `MonoGenericContext *' instead of a `MonoGenericMethod *'.
845
846 2004-03-25  Martin Baulig  <martin@ximian.com>
847
848         * loader.h (MonoMethodInflated): New typedef.
849
850         * metadata.h (MonoMethodSignature): Removed `gen_method', make
851         `generic_param_count' consume just 30 bits, added `is_inflated'
852         and `has_type_parameters' flags (one bit each).
853
854         * class.c (mono_class_inflate_generic_method): Create a
855         MonoMethodInflated instead of a MonoMethodNormal and set
856         `is_inflated' in the method signature.
857
858         * class.h (MonoGenericMethod): Removed `generic_method'.
859
860 2004-03-25  Lluis Sanchez Gual  <lluis@ximian.com>
861
862         * image.c: Make sure the name of a MonoImage is always an absolute path.
863           This fixes bug #54415.
864
865 2004-03-24  Martin Baulig  <martin@ximian.com>
866
867         * class.c (mono_class_setup_vtable): If we're a generic instance,
868         use our generic type's vtable size.
869
870 2004-03-24  Zoltan Varga  <vargaz@freemail.hu>
871
872         * appdomain.c (ves_icall_System_AppDomain_InternalUnload): Add
873         MONO_NO_UNLOAD env var as a temporary workaround for unloading 
874         problems.
875
876 2004-03-23  Martin Baulig  <martin@ximian.com>
877
878         * class.h (MonoDynamicGenericInst): Added `int count_events' and
879         `MonoEvent *events'.
880
881         * icall.c (ves_icall_MonoGenericInst_GetEvents): New interncall.
882         (typebuilder_icalls): Added "get_event_info"; calls
883         mono_reflection_event_builder_get_event_info(). 
884
885         * reflection.c (mono_reflection_generic_inst_initialize): Added
886         `MonoArray *events'.
887         (mono_reflection_event_builder_get_event_info): New function.
888
889 2004-03-23  Bernie Solomon  <bernard@ugsolutions.com>
890
891         * object.h: add mono_type_initialization_init
892
893         * object.c (mono_runtime_class_init): 
894         implement class constructor synchronization rules
895         to cope with threading issues.  
896         add mono_type_initialization_init
897
898         * appdomain.c (mono_runtime_init): call 
899         mono_type_initialization_init
900
901         * class.h: removing initializing field from MonoVTable
902
903 2004-03-23  Martin Baulig  <martin@ximian.com>
904
905         * class.c (my_mono_class_from_generic_parameter): Use
906         `param->name' if it's not NULL. 
907
908 2004-03-22 Ben Maurer  <bmaurer@users.sourceforge.net>
909
910         * class.c: do not insert non-virtual methods in the vtable.
911         * icall.c, mono-debug-debugger.c, object.c: if method->slot == -1,
912         that means the method is non-virtual. This never would have
913         happened before.
914
915 2004-03-22  Lluis Sanchez Gual  <lluis@ximian.com>
916
917         * profiler.c: Added lock for accessing coverage_hash.
918
919 2004-03-22  Martin Baulig  <martin@ximian.com>
920
921         * icall.c (ves_icall_MethodInfo_get_IsGenericMethod): Use
922         `method->method->signature->generic_param_count != 0' to make it
923         work for interface methods.
924
925 2004-03-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
926
927         * process.c: quote the string passed to the shell using g_shell_quote.
928
929 2004-03-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
930
931         * threads.c:
932         (mono_threads_manage): don't remove the finalizer thread and self
933         from the threads hash table so that mono_thread_manage can be called
934         more than once.
935
936 2004-03-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
937
938         * process.c: quote the arguments when UseShellExecute is true. Fixes
939         bug #55790.
940
941 2004-03-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
942
943         * threads.c: set mono_thread_detach as a cleanup routine for every
944         thread. This way it's always executed upon thread termination, either
945         aborted or finished normally. No more xsp hangs!
946
947 2004-03-17  Martin Baulig  <martin@ximian.com>
948
949         * class.h (MonoGenericInst): Replaced the `GList *nested' with an
950         `int count_nested' and a `MonoType **nested'.
951
952         * reflection.c (mono_reflection_bind_generic_parameters): Moved
953         most of the functionality into a new static
954         do_mono_reflection_bind_generic_parameters() and don't take a
955         `MonoType *nested_in' argument any more.  Don't compute nested
956         types here.
957         (mono_reflection_generic_inst_get_nested_types): New public method
958         to get nested types.
959
960         * class.c (mono_class_create_generic): Set `klass->nested_in' if
961         we're a nested class.
962
963         * icall.c (ves_icall_MonoGenericInst_GetNestedTypes): Call
964         mono_reflection_generic_inst_get_nested_types() to compute the
965         nested types.
966
967 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
968
969         * threads.c (ves_icall_System_Threading_Thread_Abort): Add a more
970         descriptive error message under windows.
971         
972 2004-03-17  Martin Baulig  <martin@ximian.com>
973
974         * class.c (dup_type): Added `const MonoType *original' argument;
975         copy the attrs from the original type.
976
977 2004-03-17  Martin Baulig  <martin@ximian.com>
978
979         * metadata.c (do_mono_metadata_parse_generic_inst): Use the
980         `m->generic_inst_cache' here.
981
982 2004-03-17  Zoltan Varga  <vargaz@freemail.hu>
983
984         * exception.h exception.c: Add stack_overflow_exception.
985
986 2004-03-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
987
988         * threadpool.c:
989         (overlapped_callback): call SetEvent *after* invoking the callback.
990         No need to call CloseHandle.
991
992 2004-03-16  Martin Baulig  <martin@ximian.com>
993
994         * reflection.c (mono_image_get_fieldref_token): Take a
995         `MonoReflectionField *' instead of a `MonoClassField *' and a
996         `MonoClass *'; store the `MonoReflectionField *' in the hash.
997
998 2004-03-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
999
1000         * appdomain.c: don't add the culture to the filename we're looking for
1001         if it's neutral or NULL. Fixes bug #53788. Removed redundant memset.
1002
1003 2004-03-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1004
1005         * locales.c: don't ignore symbols when doing case insensitive compares.
1006         Thanks Dick! Fixes bug #54046.
1007
1008         * threads.c: surround 'threads' usage with enter/leave in
1009         mono_thread_manage.
1010
1011 2004-03-16  Zoltan Varga  <vargaz@freemail.hu>
1012
1013         * marshal.c (mono_marshal_get_native_wrapper): Char arrays are 
1014         implicitly marshalled as [Out]. Fixes #55450.
1015
1016         (mono_marshal_get_runtime_invoke): Zero out the result if there is
1017         an exception.
1018
1019 2004-03-16  Martin Baulig  <martin@ximian.com>
1020
1021         * class.c (mono_class_from_generic_parameter): Use the actual
1022         parameter name. 
1023
1024 2004-03-16  Martin Baulig  <martin@ximian.com>
1025
1026         * reflection.c (type_get_signature_size): New static function.
1027         Compues the size of the type in a method signature.
1028         (method_get_signature_size): New static function; calls
1029         type_get_signature_size() to compute the actual size of the
1030         method's signature.
1031         (method_encode_signature): Use method_get_signature_size() to get
1032         the signature's size rather than using `nparams * 10'.
1033
1034 2004-03-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1035
1036         * file-io.h: define here WapiOverlapped on windows. I don't want the
1037         regular OVERLAPPED one.
1038
1039         * file-io.c:
1040         * threadpool.c: somehow, BindIoCompletionCallback is not found.
1041         Disabling AIO on windows.
1042
1043 2004-03-15  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1044
1045         * marshal.c: Marshal.SizeOf throws an exception for AutoLayout. Fixes
1046         bug #55385.
1047
1048 2004-03-15  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1049
1050         * appdomain.c: upgraded corlib version.
1051
1052         * file-io.c: implemented new icalls: GetSupportsAIO, BeginRead
1053         and BeginWrite. Allow opening files for asynchrnous operations.
1054
1055         * file-io.h: new struct that maps FileStreamAsyncResult.
1056         * icall.c: added new icalls.
1057         * process.[ch]: support setting child process environment variables
1058         and use the SHELL or COMSPEC when UseShellExecute is true.
1059
1060         * threadpool.[ch]: fixed warnings, moved ThreadPool icalls here. The
1061         callback for async. IO is here and also BindHandle.
1062
1063         * threads.[ch]: added mono_thread_detach and removed ThreadPool icalls
1064         from here.
1065
1066 2004-03-14  Zoltan Varga  <vargaz@freemail.hu>
1067
1068         * reflection.c (create_custom_attr): Allow len == 0.
1069
1070         * object.c (mono_class_compute_gc_descriptor): Fix descriptor
1071         computation on big-endian machines.
1072
1073 2004-03-13  Martin Baulig  <martin@ximian.com>
1074
1075         * class.h (MonoGenericInst): Added `int count_ifaces'.
1076
1077         * iclass.c (ves_icall_MonoGenericInst_GetInterfaces): Use
1078         `ginst->count_ifaces' instead `klass->interface_count' since we
1079         may get called before the vtable is created.
1080
1081         * loader.c (mono_method_get_param_names): If we're a generic
1082         instance, return and don't initialize the class.
1083
1084         * reflection.c (mono_reflection_setup_generic_class): Don't call
1085         ensure_runtime_vtable().
1086         (mono_reflection_bind_generic_parameters): Set
1087         `ginst->count_ifaces'.
1088
1089 2004-03-11  Jackson Harper <jackson@ximian.com>
1090
1091         * icall.c:
1092         * unicode.c:
1093         * unicode.h: Remove unused System.Char icalls.
1094         
1095 2004-03-11  Miguel de Icaza  <miguel@ximian.com>
1096
1097         * loader.c (mono_lookup_pinvoke_call): Call the Windows.Forms init
1098         code when we P/Invoke the first library in Windows.Forms, instead
1099         of when we first open the assembly.
1100
1101         * assembly.c: Drop the lookup from here.
1102
1103 2004-03-10  Martin Baulig  <martin@ximian.com>
1104
1105         * reflection.c (mono_reflection_get_custom_attrs): Use the correct
1106         class for properties, fields and events.  Finally fixes #54945.
1107
1108 2004-03-10  Martin Baulig  <martin@ximian.com>
1109
1110         * metadata.c (mono_metadata_class_equal): New static function;
1111         checks whether two generic instances or two generic parameters are
1112         equal.
1113         (mono_metadata_type_equal): Use mono_metadata_class_equal() to
1114         compare classes.        
1115
1116 2004-03-10  Martin Baulig  <martin@ximian.com>
1117
1118         * class.h (MonoGenericMethod): Added `gpointer reflection_info'.
1119
1120         * reflection.c (inflate_mono_method): Added `MonoObject *obj'
1121         argument and write it into the `reflection_info' field.
1122
1123         * icall.c
1124         (ves_icall_MethodBase_GetGenericMethodDefinition): New interncall.
1125         (ves_icall_MethodBase_get_HasGenericParameters): New interncall.
1126
1127 2004-03-09  Jackson Harper  <jackson@ximian.com>
1128
1129         * char-conversions.h: use 8 bits for numeric data its all we need
1130         * icall.c: numeric data is only 8 bits now.
1131
1132 2004-03-09  Martin Baulig  <martin@ximian.com>
1133
1134         * class.h (MonoProperty, MonoEvent): Added `MonoClass *parent'.
1135
1136         * class.c (init_properties, init_events): Initialize the new
1137         `parent' field.
1138
1139         * reflection.c (typebuilder_setup_properties): Likewise.
1140         (typebuilder_setup_events): Likewise.
1141
1142         * reflection.h (MonoEventInfo): Replaced `parent with
1143         `declaring_type' and `reflected_type'.
1144
1145         * icall.c (ves_icall_get_property_info): Distinguish between
1146         declaring and reflected type.
1147         (ves_icall_get_event_info): Likewise.
1148
1149 2004-03-09  Martin Baulig  <martin@ximian.com>
1150
1151         * icall.c (ves_icall_Type_GetTypeCode): Added MONO_TYPE_GENERICINST.
1152         (ves_icall_Type_GetField): Correctly set field->klass.
1153
1154 2004-03-09  Zoltan Varga  <vargaz@freemail.hu>
1155
1156         * loader.h: Fix warning.
1157
1158 2004-03-08  Miguel de Icaza  <miguel@ximian.com>
1159
1160         *  loader.c, loader.h (mono_loader_wine_init): Loads the Wine/Lib
1161         library routine if present.  Notice that it will still continue
1162         executing even if its missing, for those working on the Gtk#
1163         edition of Windows.Forms.
1164
1165         * assembly.c (do_mono_assembly_open): If loading the
1166         System.Windows.Forms call mono_loader_wini_init.
1167
1168 2004-03-04  Lluis Sanchez Gual  <lluis@ximian.com>
1169
1170         * class.h: Added MonoRemoteClass struct.
1171         * domain.c: Changed hash function for proxy_vtable_hash. It now uses a
1172         function for MonoStrings.
1173         * icall.c: In GetTransparentProxy, assign a MonoRemoteClass to the proxy.
1174         Added internal call for getting the proxy type.
1175         * marshal.c: Get the type of transparent proxies from its remote_class.
1176         Added methods that generate the IL for type checks and casts:
1177         mono_marshal_get_isinst, mono_marshal_get_castclass, 
1178         mono_marshal_get_proxy_cancast.
1179         * marshal.h: Declaration of the previous new methods.
1180         * object.c: Added new moethods for creating and updating MonoRemoteClass
1181         instances: mono_remote_class, mono_upgrade_remote_class, 
1182         * object.h: Added MonoRemoteClass reference in MonoTransparentProxy.
1183         * verify.c: FIx transparent_proxy_fields layout.
1184         * appdomain.c: Bump corlib version.
1185
1186 2004-03-04  Jackson Harper  <jackson@ximian.com>
1187
1188         * icall.c: Add icall to access char conversion tables.
1189         * char-conversions.h: Character conversion tables.
1190         * Makefile.am: Add char-conversions.h private header file.
1191         
1192 2004-03-04  Zoltan Varga  <vargaz@freemail.hu>
1193
1194         * appdomain.c (unload_thread_main): Increase unloading timeout to
1195         10 sec as a temporary workaround for Nant problems.
1196
1197 2004-02-29  Zoltan Varga  <vargaz@freemail.hu>
1198
1199         * gc.c: Add checks for GC_enable and GC_disable.
1200
1201         * string-icalls.c locales.c: Applied patch from Jaroslaw Kowalski
1202         (jaak@zd.com.pl). Fix memory corruption in String.Replace 
1203         (bug #54988).
1204         
1205 2004-02-27  Martin Baulig  <martin@ximian.com>
1206
1207         * reflection.c (mono_reflection_bind_generic_parameters): Take a
1208         `MonoReflectionType *' instead of a `MonoType *'.
1209
1210 2004-02-26  Zoltan Varga  <vargaz@freemail.hu>
1211
1212         * gc.c (run_finalize): Avoid finalizing the object representing the
1213         finalizer thread.
1214         (finalizer_thread): Fix warning.
1215
1216 2004-02-25  Martin Baulig  <martin@ximian.com>
1217
1218         * class.c (_mono_class_get_instantiation_name): Added `int offset'
1219         argument for nested types.
1220         (mono_class_create_generic): Added support for nested generictypes.
1221
1222         * class.h (MonoGenericInst): Added `MonoType *nested_in' and
1223         `GList *nested'.
1224
1225         * icall.c (ves_icall_MonoGenericInst_GetNestedTypes): New icall.
1226
1227         * reflection.c (method_encode_signature): Increase the minimum
1228         value of `size' from 10 to 11.
1229         (mono_reflection_bind_generic_parameters): Take `int type_argc'
1230         and `MonoType **types' arguments instead of the `MonoArray
1231         *types'; added `MonoType *nested_in'.  Recursively instantiate
1232         nested classes. 
1233
1234 2004-02-23  Zoltan Varga  <vargaz@freemail.hu>
1235
1236         * appdomain.h (MonoDomain): Add preallocated null_reference_ex and 
1237         stack_overflow_ex members which are used by exception handling.
1238
1239         * appdomain.c (mono_runtime_init): Initialize the new members.
1240
1241         * gc.c (mono_gc_enable): New helper function.
1242         * gc.c (mono_gc_disable): New helper function.
1243
1244 2004-02-23  Martin Baulig  <martin@ximian.com>
1245
1246         * icall.c: I must have been really stupid - make it actually work
1247         this time ;-)
1248
1249 2004-02-23  Martin Baulig  <martin@ximian.com>
1250
1251         * loader.c (method_from_memberref): Only inflate the method if
1252         it's in another klass.
1253
1254 2004-02-23  Martin Baulig  <martin@ximian.com>
1255
1256         * class.c (mono_class_inflate_generic_type): Fixed two bugs.
1257         (mono_class_init): If we're a generic instance and an interface,
1258         compute `class->interface_id'; also create `class->interfaces'
1259         here and inflate them.
1260
1261         * metadata.c (do_mono_metadata_parse_generic_inst): Compute
1262         `ginst->is_open'.
1263         (mono_type_stack_size): Fix for MONO_TYPE_GENERICINST.
1264
1265         * reflection.c (mono_image_create_token): Allow "MonoGenericInst".
1266
1267 2004-02-15  Miguel de Icaza  <miguel@ximian.com>
1268
1269         * reflection.c (method_encode_code): Improved the error message
1270         generated by the exception.
1271
1272 2004-02-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1273
1274         * icall.c: Martin did not do what he said in the ChangeLog for
1275         2004-02-18, but put back the changes for properties and events.
1276         Commenting those changes out again and adding comment to bug #54518.
1277         
1278         * process.c: removed warning.
1279
1280 2004-02-20  Zoltan Varga  <vargaz@freemail.hu>
1281
1282         * marshal.c (emit_struct_conv): Print an error message instead of
1283         asserting when a type does not have the StructLayout attribute.
1284
1285 2004-02-20  Martin Baulig  <martin@ximian.com>
1286
1287         * reflection.c (mono_type_get_object): Also use the cache for
1288         generic instances.
1289         (mono_reflection_bind_generic_parameters): Always compute
1290         `ginst->ifaces'.        
1291
1292 2004-02-20  Martin Baulig  <martin@ximian.com>
1293
1294         * class.h (MonoGenericMethod): Removed `klass'.
1295
1296         * class.c (mono_class_inflate_generic_method): Added `MonoClass
1297         *klass' argument.
1298
1299 2004-02-20  Martin Baulig  <martin@ximian.com>
1300
1301         * reflection.c (method_encode_methodspec): Actually use the
1302         uninflated signature for the memberref.
1303
1304 2004-02-20  Martin Baulig  <martin@ximian.com>
1305
1306         * class.h (MonoGenericMethod): Removed `declaring'.
1307
1308         * class.c (mono_class_inflate_generic_method): If `gmethod->klass'
1309         is NULL, compute it here.
1310
1311 2004-02-20  Martin Baulig  <martin@ximian.com>
1312
1313         * image.h (MonoImage): Added `GHashTable *generic_inst_cache'.
1314
1315         * metadata.c (mono_metadata_generic_inst_hash): New method.
1316         (mono_metadata_generic_inst_equal): New method.
1317
1318         * reflection.c (mono_reflection_bind_generic_parameters): Use the
1319         `klass->image->generic_inst_cache' cache to avoid creating
1320         duplicate MonoGenericInst's.
1321
1322         * class.c (mono_class_inflate_generic_type): Use the cache.
1323
1324 Thu Feb 19 19:39:09 CET 2004 Paolo Molaro <lupus@ximian.com>
1325
1326         * object.c: fixed gc descriptor calculation for embedded valuetypes.
1327
1328 2004-02-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1329
1330         * icall.c: added Socket.WSAIoctl icall.
1331
1332         * socket-io.[ch]: implemented
1333         ves_icall_System_Net_Sockets_Socket_WSAIoctl.
1334
1335 2004-02-19  Atsushi Enomoto  <atsushi@ximian.com>
1336
1337         * icall.c: removed IsDigit, IsSeparator, IsWhiteSpace from char_icalls.
1338
1339 2004-02-18  Urs C Muff  <umuff@quark.com>
1340
1341         * debug-mono-symfile.c, mono-debug-debugger.c, mono-debug.c: Make
1342         this work on PPC and other big-endian architectures.
1343
1344         * debug-mono-symfile.h: Prepended the names of all the `guint32'
1345         fields with an underscore to make sure they're only accessed by
1346         the read32() macro.
1347
1348 2004-02-18  Martin Baulig  <martin@ximian.com>
1349
1350         * icall.c: Put the klass->refclass changes back for methods and
1351         fields, but not for properties and events.  We're currently not
1352         distinguishing between DeclaringType and ReflectedType for
1353         properties and events, that's what caused the regressions.
1354
1355 2004-02-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1356
1357         * object.c:
1358         (mono_async_result_new): the handle can be NULL.
1359
1360         * threadpool.c: Use an event instead of a semaphore, don't initialize
1361         it until needed. This saves quite a few semaphores from being created
1362         when using the threadpool.
1363
1364 2004-02-18  Zoltan Varga  <vargaz@freemail.hu>
1365
1366         * object.c (mono_string_is_interned_lookup): Fix interning of long
1367         strings. Fixes #54473.
1368
1369         * domain.c (ldstr_equal): Optimize if the two strings are equal.
1370
1371         * icall.c: Revert the klass->refclass changes since they introduce
1372         regressions (bug #54518).
1373
1374 2004-02-18  Martin Baulig  <martin@ximian.com>
1375
1376         * class.c (mono_class_init): If we're a generic instance and don't
1377         come from a TypeBuilder, inflate our members here.
1378         (mono_class_from_generic): Removed; just use `ginst->klass' instead.
1379         (mono_class_create_generic): New public method.
1380         (mono_class_initialize_generic): Removed.
1381         (get_instantiation_name): Renamed to
1382         _mono_class_get_instantiation_name() and made it public.
1383
1384 2004-02-18  Martin Baulig  <martin@ximian.com>
1385
1386         * class.c (mono_class_inflate_generic_type): Clear the new
1387         instance's `nginst->klass' when inflating a generic instance.
1388         (mono_class_is_subclass_of): Added (basic) support for generic
1389         instances.
1390
1391 Tue Feb 17 21:40:16 CET 2004 Paolo Molaro <lupus@ximian.com>
1392
1393         * appdomain.h, domain.c: use a MonoCodeManager instead of a
1394         MonoMempool to hold compiled native code.
1395
1396 2004-02-17  Martin Baulig  <martin@ximian.com>
1397
1398         * class.h (MonoDynamicGenericInst): Added `count_properties' and
1399         `properties'.
1400
1401         * reflection.c (mono_reflection_generic_inst_initialize): Added
1402         `MonoArray *properties' argument.
1403
1404         * icall.c (ves_icall_MonoGenericInst_GetProperties): New interncall.    
1405
1406 2004-02-17  Martin Baulig  <martin@ximian.com>
1407
1408         * icall.c (ves_icall_Type_GetFields): Renamed to
1409         ves_icall_Type_GetFields_internal() and added a
1410         `MonoReflectionType *rtype' argument; pass it to
1411         mono_field_get_object() to set the field's "reflected" type.
1412         (ves_icall_Type_GetConstructors): Likewise.
1413         (ves_icall_Type_GetEvents): Likewise.
1414         (ves_icall_Type_GetMethodsByName): Added `MonoReflectionType *rtype'
1415         argument; pass it to mono_method_get_object() to set the method's
1416         "reflected" type.       
1417
1418 2004-02-17  Martin Baulig  <martin@ximian.com>
1419
1420         * class.h (MonoDynamicGenericInst): New type.
1421         (MonoGenericInst): Added `dynamic_info' and `is_dynamic' fields.
1422
1423         * icall.c (ves_icall_MonoGenericInst_GetMethods): New interncall.
1424         (ves_icall_MonoGenericInst_GetConstructors): New interncall.
1425         (ves_icall_MonoGenericInst_GetFields): New interncall.
1426
1427         * class.c (mono_class_from_generic): Don't call
1428         mono_class_initialize_generic() if this is a dynamic instance;
1429         ie. it's being created from a TypeBuilder.
1430         Use MONO_TYPE_GENERICINST for `class->this_arg.type' and
1431         `class->byval_arg.type'.
1432
1433         * reflection.c (mono_reflection_inflate_method_or_ctor): Renamed
1434         to `inflate_method' and made static.
1435         (mono_reflection_inflate_field): Removed.
1436         (mono_reflection_generic_inst_initialize): New public method.
1437
1438         * reflection.h (MonoReflectionGenericInst): Removed `methods',
1439         `ctors' and `fields'; added `initialized'.
1440
1441 2004-02-14  Zoltan Varga  <vargaz@freemail.hu>
1442
1443         * debug-helpers.c (mono_method_full_name): Fix output for empty
1444         namespaces.
1445
1446 2004-02-12  Martin Baulig  <martin@ximian.com>
1447
1448         * class.h (MonoClassField): Added `MonoType *generic_type'.
1449
1450         * reflection.c (mono_image_get_fieldref_token): Added support for
1451         instantiated generic types.
1452         (field_encode_inflated_field): Removed.
1453         (mono_image_get_inflated_field_token): Removed.
1454         (mono_reflection_inflate_field): Return a `MonoReflectionField *'.
1455
1456         * reflection.h (MonoReflectionInflatedField): Removed.
1457
1458 2004-02-12  Martin Baulig  <martin@ximian.com>
1459
1460         * metadata.h (MonoMethodHeader, MonoMethodSignature): Moved the
1461         `gen_method' field from MonoMethodHeader to MonoMethodSignature.
1462
1463         * reflection.c (mono_image_get_methodspec_token): Take a
1464         `MonoMethod *' instead of a `MonoReflectionInflatedMethod *'.
1465         (mono_image_create_token): Check whether we have a
1466         `method->signature->gen_method' and call
1467         mono_image_get_methodspec_token() if appropriate.
1468         (inflated_method_get_object): Removed.
1469         (mono_reflection_bind_generic_method_parameters): Return a
1470         `MonoReflectionMethod *', not a `MonoReflectionInflatedMethod *'.
1471         (mono_reflection_inflate_method_or_ctor): Likewise.
1472
1473         * reflection.h (MonoReflectionInflatedMethod): Removed.
1474
1475 2004-02-12  Zoltan Varga  <vargaz@freemail.hu>
1476
1477         * marshal.c (mono_marshal_get_native_wrapper): Implement proper support
1478         for custom valuetype marshalling.
1479
1480         * icall.c (icall_entries): Diagnostic -> Diagnostics. Fixes #54261.
1481
1482 2004-02-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1483
1484         * icall.c: fixed WSAGetLastError_internal name.
1485
1486 2004-02-11  Zoltan Varga  <vargaz@freemail.hu>
1487
1488         * threads.c (mono_thread_attach): Allow this to be called multiple
1489         times for a thread.
1490         
1491         * threads.c (build_wait_tids): Do not wait for ourselves.
1492
1493         * threads.c (mono_thread_pop_appdomain_ref): Avoid crash if the 
1494         appdomain list is empty.
1495
1496         * marshal.c (mono_marshal_get_native_wrapper): Do not free the
1497         memory returned by mono_string_builder_to_utf16, since it points into
1498         managed memory. Thanks to Bernie Solomon for noticing this.
1499
1500         * icall.c: Add AppDomainSetup icalls.
1501
1502         * reflection.h (MonoReflectionMethodAux): Add 'param_cattr' field.
1503
1504         * reflection.c (mono_custom_attrs_from_param): Add support for dynamic
1505         types.
1506
1507         * reflection.c (reflection_methodbuilder_to_mono_method): Save
1508         custom attributes to the method_aux struct. Also fix array indexes etc.
1509
1510         * loader.c (mono_method_get_param_names): Make dynamic case work again.
1511         
1512 Tue Feb 10 17:03:04 CET 2004 Paolo Molaro <lupus@ximian.com>
1513
1514         * icall.c, loader.c: icall cleanup: we save quite a bit of memory
1515         (both static and runtime) and reduce startup time.
1516
1517 2004-02-10  Zoltan Varga  <vargaz@freemail.hu>
1518
1519         * marshal.c (mono_marshal_get_native_wrapper): Throw an exception on
1520         AsAny marshalling conversion instead of crashing.
1521
1522         * marshal.c: Fix warnings.
1523
1524 2004-02-09  Martin Baulig  <martin@ximian.com>
1525
1526         * class.h (MonoGenericMethod): Added `MonoMethod *declaring'.
1527
1528         * reflection.h (MonoReflectionInflatedMethod): Removed the
1529         `declaring' field, it's now in the unmanaged MonoGenericMethod.
1530
1531         * reflection.c (method_encode_methodspec): Removed the `method'
1532         argument; we get it from `gmethod->declaring'.
1533         (inflated_method_get_object): Removed the `declaring' argument.
1534
1535 2004-02-09  Martin Baulig  <martin@ximian.com>
1536
1537         * class.h (MonoGenericMethod): New type.
1538         (MonoGenericInst): Remove `mtype_argc', `mtype_argv' and
1539         `generic_method'.
1540
1541         * metadata.h (MonoMethodHeader): Replaced the `geninst' field with
1542         a `MonoGenericMethod *gen_method' one.
1543
1544         * class.c (mono_class_inflate_generic_type): Take an additional
1545         `MonoGenericMethod * argument.  This is only non-NULL if we're
1546         inflating types for a generic method.   
1547         (mono_class_inflate_generic_signature): Renamed to
1548         inflate_generic_signature() and made static; take a
1549         `MonoGenericMethod *' argument instead of a `MonoGenericInst *'.
1550         (inflate_generic_header): Take a `MonoGenericMethod *' argument
1551         instead of a `MonoGenericInst *' one.
1552         (mono_class_inflate_generic_method): Likewise.
1553
1554         * reflection.c (encode_generic_method_sig): Take a
1555         `MonoGenericMethod *' argument instead of a `MonoGenericInst *'.
1556         (method_encode_methodspec): Likewise.
1557         (inflated_method_get_object): Likewise. 
1558
1559         * reflection.h (MonoReflectionGenericInst): Replaced the `ginst'
1560         field with a `MonoGenericMethod *gmethod' one.  
1561
1562 2004-02-08  Bernie Solomon  <bernard@ugsolutions.com>
1563
1564         * class.h (mono_class_has_parent): add parens to expansion
1565         so you can ! this.
1566
1567 2004-02-08  Martin Baulig  <martin@ximian.com>
1568
1569         * image.h (MonoImage): Removed `generics_cache'.
1570
1571         * class.c (mono_class_from_generic): Take a `MonoGenericInst *'
1572         instead of a `MonoType *' argument; removed the `inflate_methods'
1573         argument.  Don't inflate methods here.
1574
1575         * loader.c (find_method): If it's a generic instance, call
1576         mono_class_init() on the `sclass->generic_inst->generic_type'.
1577
1578         * metadata.c (mono_type_size): Make this work on uninitialized
1579         generic instances; call it on the `ginst->generic_type's class.
1580
1581         * reflection.c (mono_reflection_bind_generic_parameters): Call
1582         mono_class_from_generic() to create the `ginst->klass'.
1583
1584 2004-02-08  Martin Baulig  <martin@ximian.com>
1585
1586         * class.h (MonoClass): Changed type of `generic_inst' from
1587         `MonoType *' to `MonoGenericInst *'.
1588
1589 2004-02-08  Martin Baulig  <martin@ximian.com>
1590
1591         * icall.c (ves_icall_Type_BindGenericParameters): Just call
1592         mono_type_get_object(), this is now creating a `MonoGenericInst'
1593         for MONO_TYPE_GENERICINST.
1594         (ves_icall_MonoGenericInst_GetParentType): Likewise.
1595         (ves_icall_MonoGenericInst_GetInterfaces): Likewise.
1596
1597         * reflection.c (mono_type_get_object): Return a `MonoGenericInst'
1598         instead instead of a `MonoType' for MONO_TYPE_GENERICINST.
1599         (inflated_method_get_object): Added `MonoClass *refclass' argument.
1600         (mono_reflection_inflate_method_or_ctor): Correctly set declaring
1601         and reflected type.
1602
1603         * reflection.h (MonoReflectionInflatedMethod): Removed
1604         `declaring_type' and `reflected_type'.
1605
1606 2004-02-08  Martin Baulig  <martin@ximian.com>
1607
1608         * class.h (MonoGenericInst): Added `MonoType *parent' and
1609         `MonoType **ifaces'.
1610
1611         * reflection.h (MonoReflectionGenericInst): Removed `klass',
1612         `parent' and `interfaces'.
1613
1614         * reflection.c (mono_reflection_bind_generic_parameters): Take a
1615         `MonoType *' argument and return a `MonoType *'.
1616
1617         * icall.c
1618         (ves_icall_MonoGenericInst_GetParentType): New interncall.
1619         (ves_icall_MonoGenericInst_GetInterfaces): Likewise.    
1620
1621 2004-02-06  Zoltan Varga  <vargaz@freemail.hu>
1622
1623         * marshal.c (mono_marshal_get_native_wrapper): Add support for custom
1624         valuetype marshalling.
1625
1626 2004-02-06  Martin Baulig  <martin@ximian.com>
1627
1628         * class.c
1629         (mono_class_from_generic_parameter): Added TYPE_ATTRIBUTE_PUBLIC.
1630         (my_mono_class_from_generic_parameter): Likewise.
1631
1632 2004-02-06  Zoltan Varga  <vargaz@freemail.hu>
1633
1634         * debug-mono-symfile.c debug-mono-symfile.h mono-debug.c: Read the
1635         contents of the symbol files lazily.
1636
1637         * object.h (MonoThread): Add 'name' and 'name_len' fields.
1638
1639         * threads.h threads.c icall.c: New icalls for getting and setting the
1640         threads name.
1641
1642 2004-02-05  Zoltan Varga  <vargaz@freemail.hu>
1643
1644         * appdomain.c (ves_icall_System_AppDomain_InternalPushDomainRefByID): 
1645         Raise an exception when the domain is not found.
1646
1647 2004-02-03  Martin Baulig  <martin@ximian.com>
1648
1649         * reflection.c (mono_image_get_methodspec_token): Use the
1650         uninflated signature; fixes gen-33.
1651
1652 2004-02-02  Zoltan Varga  <vargaz@freemail.hu>
1653
1654         * gc.c threads.c: Make the finalizer thread a normal managed thread so
1655         the finalizer code can use thread functionality.
1656
1657         * gc.c (ves_icall_System_GC_WaitForPendingFinalizers): Fix check for 
1658         the finalizer thread.
1659
1660         * threads.c: Make some functions more robust.
1661
1662         * loader.c (mono_lookup_pinvoke_call): Another attempt at fixing #22532.
1663
1664         * metadata.h: Add new marshalling conventions.
1665
1666         * marshal.c (mono_marshal_get_native_wrapper): Add support for unicode
1667         stringbuilder marshalling. Fixes #53700.
1668
1669         * reflection.h (MonoReflectionTypeBuilder): Add 'permissions' field.
1670
1671         * reflection.c (mono_image_get_type_info): Save declarative security
1672         info.
1673
1674         * reflection.c (mono_image_get_field_info): Handle uninitialized 
1675         unmanaged fields as well.
1676
1677         * appdomain.c: Bump corlib version.
1678
1679 2004-02-01  Martin Baulig  <martin@ximian.com>
1680
1681         * loader.c (method_from_methodspec): Use `ginst->mtype_argc/v' for
1682         method type arguments.  
1683
1684 2004-01-30  Duncan Mak  <duncan@ximian.com>
1685
1686         * marshal.h: Add prototype for
1687         "ves_icall_System_Runtime_InteropServices_Marshal_AllocCoTaskMem"
1688         and
1689         "ves_icall_System_Runtime_InteropServices_Marshal_FreeCoTaskMem" to
1690         fix the build.
1691
1692 2004-01-30  Zoltan Varga  <vargaz@freemail.hu>
1693
1694         * marshal.c (ves_icall_System_Runtime_InteropServices_Marshal_AllocCoTaskMem): New icall.
1695         (ves_icall_System_Runtime_InteropServices_Marshal_FreeCoTaskMem): New icall.
1696
1697 2004-01-29  Zoltan Varga  <vargaz@freemail.hu>
1698
1699         * marshal.c (mono_marshal_get_native_wrapper): Add support for
1700         custom marshalling of valuetypes.
1701
1702         * marshal.c: Fix some warnings.
1703
1704 2004-01-29  Martin Baulig  <martin@ximian.com>
1705
1706         * class.h (MonoGenericInst): Added `mtype_argc' and `mtype_argv'
1707         for generic method parameters.
1708
1709         * reflection.c (method_encode_methodspec): Write the uninflated
1710         signature into the methodspec table.
1711         (mono_reflection_inflate_method_or_ctor): Ensure `res->declaring'
1712         is always the uninflated method.
1713         (reflection_methodbuilder_to_mono_method): Copy the generic
1714         parameters from the MethodBuilder into `header->gen_params'.
1715
1716 2004-01-29  Zoltan Varga  <vargaz@freemail.hu>
1717
1718         * class.c (mono_class_from_generic_parameter): Fix warning.
1719
1720 2004-01-27  Martin Baulig  <martin@ximian.com>
1721
1722         * class.c (mono_class_from_generic_parameter): Don't create
1723         `klass->methods' here.  
1724
1725 2004-01-26  Zoltan Varga  <vargaz@freemail.hu>
1726
1727         * loader.c (mono_lookup_pinvoke_call): Disable trimming of .dll
1728         extension since it does not work with libraries named lib<FOO>.dll.so.
1729
1730 2004-01-25  Martin Baulig  <martin@ximian.com>
1731
1732         * class.c (mono_class_inflate_generic_type): Added support for
1733         MONO_TYPE_GENERICINST.
1734
1735         * reflection.c (mono_reflection_inflate_method_or_ctor): Also
1736         inflate methods on open constructed types.      
1737
1738 2004-01-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1739
1740         * object.c: fire ProcessExit event in the root AppDomain after running
1741         Main. Fixes bug #53299.
1742
1743 Fri Jan 23 21:27:40 CET 2004 Paolo Molaro <lupus@ximian.com>
1744
1745         * socket-io.c: include the new socket-wrappers.h header.
1746         Use the wrappers instead of the unix socket functions to make the code
1747         more clear.
1748
1749 2004-01-23  Zoltan Varga  <vargaz@freemail.hu>
1750
1751         * profiler.c (merge_methods): Fix merging of profile info. Fixes #53010.
1752
1753         * loader.c (mono_lookup_pinvoke_call): Strip .dll from library names.
1754         Fixes #22532.
1755
1756 2004-01-22  Zoltan Varga  <vargaz@freemail.hu>
1757
1758         * reflection.c (mono_image_create_pefile): Handle the case when the
1759         entry point is not a MethodBuilder.
1760
1761         * reflection.h (MonoReflectionAssemblyBuilder): Change 'entry_point'
1762         field to ReflectionMethod since it is not allways a builder.
1763
1764         * reflection.c (type_get_fully_qualified_name): New helper function to
1765         return the fully qualified name of a type.
1766
1767         * reflection.c (encode_marshal_blob): Always emit the fully qualified
1768         type name for custom marshallers.
1769
1770         * reflection.c (mono_marshal_spec_from_builder): Ditto.
1771
1772         * class.c (mono_class_setup_vtable): If a parent class already 
1773         implements an interface, use the implementing methods from that class.
1774         Fixes #53148.
1775
1776 2004-01-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1777
1778         * threadpool.c: just return instead of ExitThread to allow for thread
1779         clean up earlier.
1780
1781 2004-01-21  Zoltan Varga  <vargaz@freemail.hu>
1782
1783         * icall.c (ves_icall_System_Reflection_Module_Close): Prevent assertion
1784         when closing resource modules.
1785
1786         * reflection.c (mono_image_create_pefile): Handle the case when the
1787         entry point is not a MethodBuilder.
1788
1789         * reflection.h (MonoReflectionAssemblyBuilder): Change 'entry_point'
1790         field to ReflectionMethod since it is not allways a builder.
1791
1792 2004-01-20  Bernie Solomon  <bernard@ugsolutions.com>
1793
1794         * marshal.c (mono_marshal_get_managed_wrapper): 
1795         mono_marshal_alloc takes native int so CONV_I
1796         the arg for 64bits.
1797
1798 2004-01-20  Zoltan Varga  <vargaz@freemail.hu>
1799
1800         * reflection.c (fixup_cattrs): New function to fixup the methoddef
1801         tokens in the cattr table. Fixes #53108.
1802
1803 2004-01-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1804
1805         * loader.c: don't trim ".dll" before looking up in the config file.
1806         Don't leak orig_scope. Reopened bug #22532 in the meanwhile.
1807
1808 2004-01-19  Zoltan Varga  <vargaz@freemail.hu>
1809
1810         * icall.c (ves_icall_System_Reflection_Assembly_GetManifestResourceInternal): 
1811         Return the module which contains the resource as well.
1812         (ves_icall_System_Reflection_Module_Close): New icall.
1813
1814         * appdomain.c: Bump corlib version number.
1815
1816         * image.c (mono_image_addref): New public function.
1817
1818         * assembly.c: Call mono_image_addref.
1819
1820         * reflection.c (mono_module_get_object): Increase reference count of 
1821         the image.
1822
1823         * loader.c (mono_lookup_pinvoke_call): Strip .dll from library names.
1824         Fixes #22532.
1825
1826         * exception.h exception.c loader.h loader.c icall.c marshal.h marshal.c:
1827         Applied patch from Bernie Solomon  <bernard@ugsolutions.com>. Throw
1828         proper exceptions on DllImport problems.
1829
1830 Mon Jan 19 17:50:27 CET 2004 Paolo Molaro <lupus@ximian.com>
1831
1832         * class.c, metadata.c: eliminate CSIZE macro.
1833
1834 2004-01-19  Lluis Sanchez Gual  <lluis@ximian.com>
1835
1836         * icall.c: Added ves_icall_type_IsInstanceOf internal call.
1837         * object.h: Added async_callback field in MonoAsyncResult.
1838         * marshal.c: In mono_delegate_begin_invoke, set the value of async_callback.
1839         * verify.c: Added async_callback in MonoAsyncResult layout.
1840
1841 2004-01-17  Zoltan Varga  <vargaz@freemail.hu>
1842
1843         * reflection.c (mono_reflection_get_custom_attrs): Add support
1844         for Modules.
1845
1846 2004-01-16  Zoltan Varga  <vargaz@freemail.hu>
1847
1848         * marshal.c (mono_string_builder_to_utf8): Fix stringbuilder 
1849         marshalling.
1850         (mono_marshal_method_from_wrapper): Add null pointer check.
1851
1852 2004-01-16  Martin Baulig  <martin@ximian.com>
1853
1854         * debug-mono-symfile.h: Set version number to 36 and reflect
1855         latest symbol writer changes.
1856
1857 2004-01-16  Zoltan Varga  <vargaz@freemail.hu>
1858
1859         * class.c (mono_bounded_array_class_get): Set 'bounded' to FALSE for
1860         multi-dimensional arrays.
1861         (mono_class_is_assignable_from): Check vectors<->one dim. arrays.
1862         (mono_class_from_mono_type): Use bounded_array_class_get.
1863         
1864         * class.c (mono_bounded_array_class_get): New function which takes
1865         a 'bounded' bool argument to distinguish vectors from one dimensional
1866         arrays.
1867
1868         * icall.c (ves_icall_System_Array_CreateInstanceImpl): Call 
1869         bounded_array_class_get if the array has bounds.
1870
1871         * icall.c (ves_icall_System_Reflection_Assembly_InternalGetType): 
1872         Search modules loaded using AssemblyBuilder:AddModule as well.
1873
1874 2004-01-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1875
1876         * appdomain.c: increased corlib version.
1877         * filewatcher.c: removed g_print.
1878         * icall.c:
1879         (get_property_info): only allocate what is actually requested.
1880         (ves_icall_Type_GetInterfaces): free the bitset in case of early error.
1881
1882 2004-01-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1883
1884         * Makefile.am: added filewatcher.[ch]
1885         * filewatcher.[ch]: FileSystemWatcher runtime support.
1886         * icall.c: added new FSW icalls.
1887
1888 Tue Jan 13 20:03:17 CET 2004 Paolo Molaro <lupus@ximian.com>
1889
1890         * string-icalls.c: fix stringbuilder regression as suggested by
1891         Iain McCoy <iain@mccoy.id.au>.
1892
1893 2004-01-13  Zoltan Varga  <vargaz@freemail.hu>
1894
1895         * process.c (process_read_stringtable_block): Recognize '007f' as
1896         a language neutral stringtable block.
1897
1898 2004-01-12  Patrik Torstensson
1899
1900         * object.h (MonoStringBuilder) : Changed layout to support our
1901         new stringbuilder class.
1902         * marshal.c: Change marshalling to support the new layout of 
1903         string builder.
1904         * appdomain.c: increased version number because new layout of
1905         string builder.
1906
1907 2004-01-12  Zoltan Varga  <vargaz@freemail.hu>
1908
1909         * appdomain.c (ves_icall_System_AppDomain_LoadAssembly): Receive the
1910         assembly name as an string instead of an AssemblyName, since it is
1911         easier to extract info from it.
1912
1913         * appdomain.c (mono_domain_assembly_preload): Look for assemblies in
1914         the culture subdirectories too. Fixes #52231.
1915
1916 2004-01-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1917
1918         * icall.c: renamed ves_icall_Type_GetMethods to GetMethodsByName.
1919         It takes 2 new parameters with an optional name for the method to look
1920         for and case ignoring info.
1921
1922         * threadpool.c: removed unused variable.
1923
1924 2004-01-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1925
1926         * icall.c: renamed ves_icall_Type_GetProperties to GetPropertiesByName.
1927         It takes 2 new parameters with an optional name for the property to look
1928         for and case ignoring info.
1929         Fixes bug #52753.
1930
1931 2004-01-09  Zoltan Varga  <vargaz@freemail.hu>
1932
1933         * reflection.c: Applied patch from Benjamin Jemlich (pcgod@gmx.net).
1934         Fix #52451.
1935
1936 2004-01-08  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1937
1938         * appdomain.c:
1939         * assembly.c: escape the uri before passing it to g_filename_from_uri.
1940         Fixes bug #52630.
1941
1942 2004-01-07  Zoltan Varga  <vargaz@freemail.hu>
1943
1944         * reflection.c: Add support for more than one unmanaged resource.
1945
1946         * icall.c (ves_icall_get_enum_info): Store the value of the enum fields
1947         in field->def_value, as done in all other cases.
1948
1949         * reflection.c (mono_reflection_get_custom_attrs): Add support for
1950         TypeBuilders.
1951
1952         * reflection.c (mono_reflection_create_runtime_class): Remove 
1953         errorneous assignment to klass->element_class, since it is already
1954         done in mono_reflection_setup_internal_class.
1955
1956 2004-01-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
1957
1958         * gc.c: added missing LeaveCriticalSection.
1959         * icall.c: indented a couple of lines.
1960         * threadpool.c: remove dangling LeaveCriticalSection. Don't wait forever
1961         if we call EndInvoke inside a callback. Fixes bug #52601.
1962
1963 2004-01-07  Martin Baulig  <martin@ximian.com>
1964
1965         * mono-debug-debugger.h
1966         (MonoDebuggerIOLayer): Added `GetCurrentThreadID'.
1967
1968 2004-01-06  Miguel de Icaza  <miguel@ximian.com>
1969
1970         * appdomain.c: Use messages in NotImplementedException.
1971
1972         * exception.c (mono_get_exception_not_implemented): Now this takes
1973         a message argument.
1974
1975         * marshal.c (emit_str_to_ptr_conv): g_warning and throw an
1976         exception instead of g_asserting an aborting when something is not
1977         implemented.
1978
1979         Add some inline docs.
1980
1981 2004-01-05  Zoltan Varga  <vargaz@freemail.hu>
1982
1983         * reflection.h: Update after changes to object layout.
1984
1985         * reflection.c: Implement saving of unmanaged aka win32 resources.
1986
1987         * appdomain.c: Bump version number.
1988
1989         * appdomain.c (ves_icall_System_AppDomain_InternalSetDomainByID): 
1990         Handle missing domains gracefully.
1991
1992 2004-01-05  Atsushi Enomoto <atsushi@ximian.com>
1993
1994         * file-io.c : On Windows, there are much more invalid_path_chars.
1995
1996 Fri Jan 2 13:35:48 CET 2004 Paolo Molaro <lupus@ximian.com>
1997
1998         * class.h, object.c: prepare for GetType () speedup.
1999
2000 2003-12-24  Atsushi Enomoto <atsushi@ximian.com>
2001
2002         * profiler.c: workaround for --profile null reference exception on
2003           cygwin. Patch by Patrik Torstensson.
2004
2005 2003-12-22  Bernie Solomon  <bernard@ugsolutions.com>
2006
2007         * marshal.c: (ves_icall_System_Runtime_InteropServices_Marshal_Read/WriteXXX)
2008         make work for unaligned access.
2009
2010 Mon Dec 22 18:37:02 CET 2003 Paolo Molaro <lupus@ximian.com>
2011
2012         * class.c: small cleanup (class->fields [i] -> field).
2013         * image.c: check address of metadata is valid.
2014
2015 2003-12-22  Zoltan Varga  <vargaz@freemail.hu>
2016
2017         * assembly.h assembly.c (mono_assembly_loaded): New public function to
2018         search the list of loaded assemblies.
2019
2020         * reflection.c (mono_reflection_type_from_name): Use 
2021         mono_assembly_loaded instead of mono_image_loaded.
2022
2023         * reflection.c: Fix warnings.
2024
2025 2003-12-20  Zoltan Varga  <vargaz@freemail.hu>
2026
2027         * image.h (MonoImage): Add a new 'dynamic' field to denote that the image 
2028         is dynamic. This is needed since an assembly can contain both dynamic and
2029         non-dynamic images.
2030
2031         * class.c loader.c metadata.c object.c: Use image->dynamic instead of 
2032         assembly->dynamic.
2033
2034         * icall.c reflection.c: Add new AssemblyBuilder:AddModule icall.
2035
2036         * reflection.h (MonoReflectionAssemblyBuilder): Add 'loaded_modules' field
2037         to store modules loaded using AddModule.
2038
2039         * reflection.c (mono_image_fill_file_table): Generalize this so it works
2040         on Modules.
2041
2042         * reflection.c (mono_image_fill_export_table_from_class): New helper function.
2043
2044         * reflection.c (mono_image_fill_export_table_from_module): New function to
2045         fill out the EXPORTEDTYPES table from a module.
2046
2047         * reflection.c (mono_image_emit_manifest): Refactor manifest creation code
2048         into a separate function. Also handle loaded non-dynamic modules.
2049
2050         * reflection.c (mono_image_basic_init): Fix memory allocation.
2051
2052         * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
2053
2054         * assembly.c (mono_assembly_load_references): Make this public.
2055
2056 2003-12-19  Martin Baulig  <martin@ximian.com>
2057
2058         * class.c (mono_class_initialize_generic): Made this static, take
2059         a `MonoGenericInst *' instead of a `MonoClass *'.
2060         (mono_class_from_generic): Call mono_class_initialize_generic()
2061         unless we're already initialized or being called from
2062         do_mono_metadata_parse_generic_inst().
2063
2064         * class.h (MonoGenericInst): Added `initialized' and
2065         `init_pending' flags.
2066
2067         * metadata.c (do_mono_metadata_parse_generic_inst): Don't call
2068         `mono_class_init (gklass)' or mono_class_initialize_generic()
2069         here; set `generic_inst->init_pending' while parsing the
2070         `type_argv'.
2071
2072 2003-12-19  Bernie Solomon  <bernard@ugsolutions.com>
2073
2074         * locales.c: include string.h for memxxx prototypes
2075
2076 2003-12-19  Zoltan Varga  <vargaz@freemail.hu>
2077
2078         * icall.c (ves_icall_MonoField_GetValueInternal): Do not run the class
2079         constructor when accessing literal fields.
2080
2081 2003-12-17  Zoltan Varga  <vargaz@freemail.hu>
2082
2083         * appdomain.c (MONO_CORLIB_VERSION): Bump corlib version.
2084
2085         * reflection.c (assembly_add_resource_manifest): New function to fill
2086         the MANIFESTRESOURCE table.
2087
2088         * reflection.c (mono_image_build_metadata): Emit MANIFESTRESOURCE table.
2089
2090         * reflection.h: Update to changes in class layout.
2091
2092         * icall.c (ves_icall_System_Environment_get_HasShutdownStarted): 
2093         Reenable call to mono_runtime_is_shutting_down ().
2094
2095         * appdomain.c (mono_runtime_is_shutting_down): New helper function to
2096         determine if the runtime is shutting down.
2097
2098 2003-12-16  Jackson Harper <jackson@ximian.com>
2099
2100         * icall.c: comment out call to mono_runtime_is_shutting_down to
2101         fix build.
2102         
2103 2003-12-16  Zoltan Varga  <vargaz@freemail.hu>
2104
2105         * icall.c (ves_icall_System_Reflection_Assembly_GetManifestResourceInternal): Add support for loading resources from modules.
2106         (ves_icall_System_Environment_get_HasShutdownStarted): New icall.
2107
2108 2003-12-15  Bernie Solomon  <bernard@ugsolutions.com>
2109
2110         * reflection.c: move definition of swap_with_size
2111         to before its first call
2112
2113 2003-12-15  Zoltan Varga  <vargaz@freemail.hu>
2114
2115         * appdomain.c (mono_runtime_is_shutting_down): New public function.
2116
2117         * icall.c (ves_icall_System_Environment_get_HasShutdownStarted): New
2118         icall.
2119
2120         * object.c: Fix warnings.
2121
2122         * icall.c (ves_icall_Type_Get...): Only consider inherited static
2123         members if FlattenHierarchy is set.
2124
2125         * reflection.c (mono_image_add_decl_security): New function to emit
2126         declarative security.
2127
2128         * reflection.h reflection.c: Add support for declarative security.
2129
2130         * appdomain.c (MONO_CORLIB_VERSION): Bump version number.
2131         
2132 2003-12-13  Zoltan Varga  <vargaz@freemail.hu>
2133
2134         appdomain.c (MONO_CORLIB_VERSION): Bump version number.
2135         
2136         * appdomain.c verify.c: Moved corlib version checking into its own
2137         function in appdomain.c since it needs to create vtables etc.
2138
2139 2003-12-13  Patrik Torstensson <p@rxc.se>
2140
2141         * marshal.c (mono_remoting_wrapper): Fix bug 48015, using TP as this 
2142         instead of unwrapped server.
2143
2144 2003-12-12  Zoltan Varga  <vargaz@freemail.hu>
2145
2146         * verify.c (check_corlib): Fix field index.
2147
2148 2003-12-10  Zoltan Varga  <vargaz@freemail.hu>
2149
2150         * icall.c: Applied patch from Todd Berman (tbermann@gentoo.org). New
2151         GetGacPath icall.
2152
2153 2003-12-10  Bernie Solomon  <bernard@ugsolutions.com>
2154
2155         * process.c:  (ves_icall_System_Diagnostics_Process_GetWorkingSet_internal
2156         ves_icall_System_Diagnostics_Process_SetWorkingSet_internal):
2157         cope with sizeof(size_t) != sizeof(guint32).
2158
2159 2003-12-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
2160
2161         * process.[ch]: the 'pid' field in MonoProcInfo stores GetLastError
2162         in case of failure.
2163
2164 2003-12-10  Mark Crichton <crichton@gimp.org>
2165
2166         * icall.c: removed the GetNonZeroBytes.  We now handle this case
2167         in managed code.
2168
2169         * rand.c, rand.h: Same here.  Also cleaned up the clode slightly.
2170
2171 Tue Dec 9 15:36:18 CET 2003 Paolo Molaro <lupus@ximian.com>
2172
2173         * class.h, class.c, icall.c, marshal.c, object.c: ignore fields
2174         marked as deleted.
2175
2176 2003-12-09  Zoltan Varga  <vargaz@freemail.hu>
2177
2178         * verify.c (check_corlib): Handle the case when the version field is 
2179         initialized by a static constructor.
2180
2181 2003-12-08  Patrik Torstensson  <p@rxc.se>
2182
2183     * rand.c (InternalGetBytes): Implemented win32 version with cryptapi
2184
2185 2003-12-08  Martin Baulig  <martin@ximian.com>
2186
2187         * icall.c (ves_icall_TypeBuilder_define_generic_parameter): Return
2188         a MonoReflectionGenericParameter, also take the parameter index
2189         and name as arguments.
2190         (ves_icall_MethodBuilder_define_generic_parameter): Likewise.
2191         (ves_icall_MonoGenericParam_initialize): New interncall.
2192         (ves_icall_Type_make_byref_type): New interncall.
2193
2194         * reflection.h (MonoReflectionGenericParam): Derive from
2195         MonoReflectionType, not just from MonoObject.  Added `refobj' and
2196         `index' fields.
2197
2198         * reflection.c (mono_reflection_define_generic_parameter): Create
2199         and return a new MonoReflectionGenericParam; don't initialize the
2200         constraints here.
2201         (mono_reflection_initialize_generic_parameter): New public method;
2202         initializes the constraints and creates the `param->pklass'.
2203
2204 2003-12-08  Zoltan Varga  <vargaz@freemail.hu>
2205
2206         * reflection.h reflection.c: Use the new fields 'num_types', 
2207         'num_fields' and 'num_methods' to track the number of types etc.
2208
2209         * verify.c (check_corlib): Check corlib version number.
2210
2211 2003-12-07  Zoltan Varga  <vargaz@freemail.hu>
2212
2213         * marshal.c (mono_marshal_method_from_wrapper): Remove assert so this
2214         function works on all methods.
2215
2216 2003-12-07  Lluis Sanchez Gual  <lluis@ximian.com>
2217
2218         * domain.c, loader.h: Added IRemotingTypeInfo interface in MonoDefaults.
2219         * icall.c: in, ves_icall_Remoting_RealProxy_GetTransparentProxy set
2220         the custom_type_info flag of the transparent proxy.
2221         * object.c: Added method mono_object_isinst_mbyref for casting mbyref
2222         objects that supports IRemotingTypeInfo.
2223         * object.h: Added custom_type_info field in transparent proxy.
2224
2225 2003-12-06  Martin Baulig  <martin@ximian.com>
2226
2227         * class.c (mono_class_create_from_generic): Removed.
2228         (mono_class_from_generic): Check `ginst->klass' before doing
2229         anything else.  This is important to fully support "recursive"
2230         generic types.
2231
2232         * metadata.c (do_mono_metadata_parse_generic_inst): Create an
2233         empty `generic_inst->klass' before doing anything else.
2234
2235 2003-12-06  Dick Porter  <dick@ximian.com>
2236
2237         * verify.c: 
2238         * object.h:
2239         * icall.c:
2240         * locales.c: Use C structs to access class fields.  Don't do a
2241         conversion between MonoString and UChar because both are
2242         platform-endian UTF-16.  Compare now takes startindex and count
2243         parameters.  Add a char overload for IndexOf.  Speed up the
2244         invariant string IndexOf.
2245
2246 2003-12-05  Zoltan Varga  <vargaz@freemail.hu>
2247
2248         * Makefile.am (monosn_LDADD): Fix parallel build.
2249
2250 2003-12-04  Martin Baulig  <martin@ximian.com>
2251
2252         * icall.c
2253         (ves_icall_type_GetTypeCode): Added MONO_TYPE_VAR and MONO_TYPE_MVAR.
2254         (ves_icall_Type_make_array_type): New interncall.       
2255
2256 2003-12-04  Martin Baulig  <martin@ximian.com>
2257
2258         * locales.c: also change it in the !HAVE_ICU case.
2259
2260 2003-12-04  Dick Porter  <dick@ximian.com>
2261
2262         * icall.c:
2263         * locales.c: construct_compareinfo is now in CompareInfo, not
2264         CultureInfo.
2265
2266 2003-12-04  Zoltan Varga  <vargaz@freemail.hu>
2267
2268         * image.c (mono_image_load_file_for_image): Cache loaded images in the
2269         image->files array.
2270
2271         * image.c (load_class_name): Load class names from the EXPORTEDTYPES
2272         table as well.
2273
2274         * assembly.c (mono_assembly_load_references): Only load references
2275         once.
2276
2277         * class.c (mono_class_from_name): Avoid linear search of the 
2278         EXPORTEDTYPE table.
2279
2280         * loader.c (mono_field_from_token): Cache lookups of fieldrefs as well.
2281
2282 2003-12-03  Zoltan Varga  <vargaz@freemail.hu>
2283
2284         * image.h (MonoImage): Add 'field_cache' field.
2285
2286         * loader.c (mono_field_from_token): Cache field lookups.
2287         
2288         * reflection.c (mono_module_get_object): Fix name property.
2289
2290         * icall.c (ves_icall_get_enum_info): Update after changes to 
2291         mono_metadata_get_constant_index ().
2292
2293         * icall.c: Get rid of get_type_info icall, use a separate icall for
2294         each type property to avoid needless memory allocations. Fixes #51514.
2295
2296         * metadata.c (mono_metadata_get_constant_index): Add a 'hint' parameter
2297         to avoid needless binary searches.
2298
2299         * class.c (class_compute_field_layout): Move the initialization of
2300         field->def_value to mono_class_vtable ().
2301
2302         * class.c (mono_class_layout_fields): Enable GC aware auto layout for
2303         non-corlib types.
2304
2305         * object.c (mono_object_allocate): Make it inline.
2306
2307         * object.c (mono_object_allocate_spec): Make it inline.
2308         
2309 2003-12-02  Dick Porter  <dick@ximian.com>
2310
2311         * locales.c (create_NumberFormat): NumberFormatInfo construction.
2312         Patch by Mohammad DAMT (mdamt@cdl2000.com).
2313
2314 2003-12-01  Dick Porter  <dick@ximian.com>
2315
2316         * threads.c: Fix signature and call in CreateMutex and
2317         CreateEvent.
2318
2319 2003-12-01  Dick Porter  <dick@ximian.com>
2320
2321         * icall.c: 
2322         * locales.c: Implement string compares and searching
2323
2324         * object.h: Add extra Thread field
2325
2326 2003-11-30  Zoltan Varga  <vargaz@freemail.hu>
2327
2328         * reflection.c (fixup_method): Add support for MonoCMethod.
2329
2330 2003-11-28  Zoltan Varga  <vargaz@freemail.hu>
2331
2332         * gc.c: Fix hangs and error messages when GC_DONT_GC is set.
2333
2334         * reflection.c (assembly_name_to_aname): Allow extra characters in
2335         assembly names. Fixes #51468.
2336
2337 2003-11-26  Zoltan Varga  <vargaz@freemail.hu>
2338
2339         * exception.c (mono_exception_from_name_domain): New helper function.
2340
2341         * appdomain.c (ves_icall_System_AppDomain_createDomain): Create the
2342         exception object in the correct domain.
2343
2344         * appdomain.c (ves_icall_System_AppDomain_LoadAssemblyRaw): Fix 
2345         formatting + make a copy a the input data.
2346
2347         * loader.c (mono_get_method_from_token): Methods which contain
2348         native code do not have entries in the ImplMap.
2349
2350         (ves_icall_System_AppDomain_LoadAssemblyRaw): Fix exception throw.
2351         Thanks to Gonzalo for spotting this.
2352         
2353         * appdomain.c (ves_icall_System_AppDomain_LoadAssemblyRaw): Applied
2354         patch from ztashev@openlinksw.co.uk (Zdravko Tashev). New icall.
2355
2356         * assembly.h (mono_assembly_load_from): Split the second part of 
2357         assembly loading into a new public function.
2358
2359         * exception.h (mono_get_exception_bad_image_format): New function.
2360
2361 2003-11-24  Zoltan Varga  <vargaz@freemail.hu>
2362
2363         icall.c (ves_icall_System_Reflection_Assembly_InternalGetType): 
2364         Enumerate all modules inside a dynamic assembly. Fixes #51293.
2365         
2366         * icall.c: Add new icall for creating dynamic methods.
2367
2368         * loader.h debug-helpers.c: Add new wrapper type for dynamic methods.
2369
2370         * reflection.h (MonoReflectionDynamicMethod): Fix type of bool fields.
2371
2372         * reflection.c (mono_reflection_create_dynamic_method): New icall to
2373         create a dynamic method.
2374
2375         * reflection.c (resolve_object): New helper function.
2376
2377         * reflection.c: Generalize ReflectionMethodBuilder and the functions
2378         which manipulate it so they can also work on dynamic methods.
2379
2380         * reflection.c (reflection_method_builder_to_mono_method): Avoid 
2381         creating the MonoReflectionMethodAux structure if it is not needed.
2382         
2383         * reflection.h verify.c: Update after changes to object layout.
2384
2385         * reflection.c (method_builder_encode_signature): Fix compilation on
2386         gcc 2.95.x.
2387
2388 2003-11-21  Lluis Sanchez Gual  <lluis@ximian.com>
2389
2390         * appdomain.h: Added support for context static fields. Added static_data
2391           field to MonoAppContext and renamed thread_static_fields to a more
2392           generic special_static_fields in MonoAppDomain, since it can now contain
2393           context static fields.
2394         * domain.c: Updated hashtable name.
2395         * object.c: Replaced field_is_thread_static() for a more generic
2396           field_is_special_static() which also checks for context static attribute.
2397           In mono_class_vtable(), added support for static context fields.
2398         * threads.c: Changed methods that manage thread static fields to more
2399           generic methods so they can be reused both for thread and context static
2400           data.
2401         * threads.h: Declared some new methods.
2402
2403 2003-11-21  Zoltan Varga  <vargaz@freemail.hu>
2404
2405         * reflection.h: Update after changes to the managed types.
2406
2407         * reflection.c (encode_custom_modifiers): New helper function.
2408
2409         * reflection.c (method_encode_signature): Emit custom modifiers.
2410
2411         * reflection.c (field_encode_signature): Emit custom modifiers.
2412
2413 2003-11-18  Zoltan Varga  <vargaz@freemail.hu>
2414
2415         * reflection.h (MonoReflectionAssemblyName): Applied patch from Laurent Morichetti (l_m@pacbell.net). Fix type of 'flags' field.
2416
2417         * icall.c (ves_icall_System_ValueType_Equals): New optimized 
2418         implementation.
2419
2420         * icall.c (ves_icall_System_ValueType_InternalGetHashCode): New 
2421         icall.
2422
2423         * object.c (mono_field_get_value_object): New function.
2424
2425         * object.c appdomain.h appdomain.c: Make out_of_memory_ex domain
2426         specific.
2427
2428 2003-11-17  Zoltan Varga  <vargaz@freemail.hu>
2429
2430         * appdomain.c (mono_runtime_get_out_of_memory_ex): New function to
2431         return a preallocated out-of-memory exception instance.
2432
2433         * object.c (out_of_memory): Use the new function.
2434
2435         * metadata.c (mono_metadata_parse_type): Handle the case when the byref
2436         flag is before the custom modifiers. Fixes #49802.
2437
2438 2003-11-16  Martin Baulig  <martin@ximian.com>
2439
2440         * class.c (mono_class_is_open_constructed_type): Implemented the
2441         MONO_TYPE_GENERICINST case.
2442
2443 2003-11-16  Zoltan Varga  <vargaz@freemail.hu>
2444
2445         * assembly.c (mono_assembly_fill_assembly_name): New function to
2446         fill out the MonoAssemblyName structure.
2447         (mono_assembly_open): Use the new function.
2448
2449         * icall.c (fill_reflection_assembly_name): New helper function.
2450
2451         * icall.c (ves_icall_System_Reflection_Assembly_FillName): Use the
2452         new function.
2453
2454         * icall.c (ves_icall_System_Reflection_Assembly_InternalGetAssemblyName): New icall.
2455
2456 2003-11-15  Martin Baulig  <martin@ximian.com>
2457
2458         * class.c (mono_class_is_open_constructed_type): New public
2459         function; checks whether a type is an open constructed type,
2460         ie. whether it still contains type parameters.
2461         (mono_class_inflate_generic_type): If we're a type parameter and
2462         the inflated type is also a MONO_TYPE_(M)VAR, return the original
2463         type.
2464
2465         * class.h (MonoGenericInst): Added `guint32 is_open'.
2466
2467         * loader.c (method_from_methodspec): Check whether we're an open
2468         or closed constructed type and set `ginst->is_open'.
2469
2470         * reflection.c (mono_reflection_bind_generic_parameters): Check
2471         whether we're an open or closed constructed type and set
2472         `ginst->is_open'.
2473         (mono_reflection_inflate_method_or_ctor): Don't inflate methods
2474         from open constructed types.
2475
2476 2003-11-15  Martin Baulig  <martin@ximian.com>
2477
2478         * reflection.c (mono_reflection_bind_generic_parameters): If we're
2479         a generic instance (instead of a generic type declaration) with
2480         unbound generic parameters, bind them to our actual types.
2481
2482 2003-11-14  Martin Baulig  <martin@ximian.com>
2483
2484         * reflection.h (MonoReflectionGenericInst): Added `MonoArray *interfaces'.
2485
2486         * reflection.c (mono_reflection_bind_generic_parameters): If we're
2487         an interface type, populate `res->interfaces' with instantiated
2488         versions of all the interfaces we inherit.
2489
2490 2003-11-13  Aleksey Demakov  <avd@openlinksw.com>
2491
2492         * assembly.c (mono_assembly_load): Fixed problem finding mscorlib.dll
2493         when MONO_PATH is set but doesn't contain the install dir.
2494
2495 2003-11-13  Gonzalo Paniagua Javier <gonzalo@ximian.com>
2496
2497         * icall.c:
2498         (ves_icall_Type_GetInterfaces): don't return an interface twice when
2499         it's also implemented in base classes. Fixes bug #50927.
2500
2501 2003-11-13  Zoltan Varga  <vargaz@freemail.hu>
2502
2503         * gc.c (ves_icall_System_GC_WaitForPendingFinalizers): Avoid deadlocks
2504         if this method is called from a finalizer. Fixes #50913.
2505
2506 2003-11-12  Miguel de Icaza  <miguel@ximian.com>
2507
2508         * threads.c: Implement VolatileRead/VolatileWrite
2509
2510         * icall.c: Add new icalls for VolatileRead/VolatileWrite
2511
2512 2003-11-12  Zoltan Varga  <vargaz@freemail.hu>
2513
2514         * icall.c (ves_icall_System_Reflection_Assembly_GetTypes): Applied 
2515         patch from Danilo Sagan (dsegan@gmx.net). Fix compilation under gcc
2516         2.95.3.
2517
2518         * assembly.c (mono_assembly_open): Fix windows build. Applied patch 
2519         from Peter Ross (pro@missioncriticalit.com).
2520         
2521 2003-11-12  Lluis Sanchez Gual  <lluis@ximian.com>
2522
2523         * icall.c: Added internal call for System.Environment::GetMachineConfigPath
2524
2525 2003-11-12  Zoltan Varga  <vargaz@freemail.hu>
2526
2527         * assembly.c (mono_assembly_load_references): Disable check because it
2528         triggers on older corlibs which lots of people have.
2529
2530 2003-11-12  Jackson Harper  <jackson@ximian.com>
2531
2532         * assembly.c: Change corlib name to mscorlib. Add a temp. hack to
2533         load corlib.dll if mscorlib.dll is not found.
2534         * assembly.h: Remove corlib name define.
2535         * class.c:
2536         * domain.c:
2537         * image.c: Change corlib name to mscorlib.
2538         
2539 2003-11-12  Zoltan Varga  <vargaz@freemail.hu>
2540
2541         * debug-mono-symfile.c: Add patch from FreeBSD ports tree.
2542
2543 2003-11-11  Miguel de Icaza  <miguel@ximian.com>
2544
2545         * appdomain.h: Added loader_optimization here to sync with the C#
2546         code, and add disallow_binding_redirects field.
2547
2548 2003-11-11  Zoltan Varga  <vargaz@freemail.hu>
2549
2550         * mono-debug.c (mono_debug_add_method): Ignore unknown modules.
2551
2552         * reflection.c (mono_image_build_metadata): Fix crash on modules
2553         with no types.
2554
2555         * reflection.h (MonoMethodInfo): Track changes to the managed structure.
2556
2557         * icall.c (ves_icall_get_method_info): Return callingConvention as
2558         well.
2559
2560         * icall.c (ves_icall_System_Reflection_Assembly_GetNamespaces): Add 
2561         namespaces from the EXPORTEDTYPE table as well.
2562
2563         * icall.c (ves_icall_System_Reflection_Assembly_GetTypes): Merge types
2564         from all modules inside the assembly.
2565         
2566 2003-11-11  Martin Baulig  <martin@ximian.com>
2567
2568         * reflection.c (mono_reflection_bind_generic_parameters): Make
2569         this work for interfaces.
2570
2571 2003-11-11  Martin Baulig  <martin@ximian.com>
2572
2573         * mono-debug.c (mono_debug_add_type): Ignore unknown modules.
2574
2575 2003-11-11  Martin Baulig  <martin@ximian.com>
2576
2577         * reflection.c (mono_reflection_inflate_method_or_ctor): Allow
2578         "MonoInflatedMethod" and "MonoInflatedCtor".
2579
2580 2003-11-11  Zoltan Varga  <vargaz@freemail.hu>
2581
2582         * reflection.c (resolution_scope_from_image): Use the assembly table
2583         from the manifest module, since other modules don't have it.
2584
2585         * debug-helpers.c (mono_type_full_name): New helper function.
2586
2587         * image.h (MonoAssembly): Change 'dynamic' to a boolean.
2588
2589         * image.c (mono_image_load_file_for_image): New public function which
2590         is a replacement for the load_file_for_image in class.c.
2591
2592         * assembly.c (mono_assembly_load_module): A wrapper for the function
2593         above which does assembly association and reference loading too.
2594
2595         * class.c (mono_class_from_name): Call mono_assembly_load_module.
2596
2597 2003-11-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
2598
2599         * appdomain.c: not all of the attributes for the full assembly name
2600         are required and the order doesn't matter. Fixes bug #50787.
2601
2602 2003-11-10  Dick Porter  <dick@ximian.com>
2603
2604         * locales.c: Use platform-endian UTF16
2605
2606 2003-11-10  Zoltan Varga  <vargaz@freemail.hu>
2607
2608         * reflection.c: Emit FILE and EXPORTEDTYPE tables.
2609         
2610 2003-11-10  Martin Baulig  <martin@ximian.com>
2611
2612         * metadata.c
2613         (mono_metadata_load_generic_params): Make this actually work.
2614
2615         * reflection.c (mono_reflection_bind_generic_parameters): If our
2616         parent is a generic instance, pass all the `types' to it, no
2617         matter whether it has the same number of type parameters or not.
2618
2619 2003-11-10  Zoltan Varga  <vargaz@freemail.hu>
2620
2621         * reflection.c: Emit FILE and EXPORTEDTYPE tables.
2622
2623         * assembly.c (mono_assembly_load_references): Move the image<->assembly
2624         assignment code to this function so it gets called recursively for all
2625         modules.
2626
2627         * image.c (load_modules): Remove the assembly assignment since it is
2628         now done by mono_assembly_load_references.
2629         
2630         * icall.c (ves_icall_System_Reflection_Assembly_InternalGetType): 
2631         Add 'module' argument.
2632         (mono_module_get_types): New helper function.
2633         (ves_icall_System_Reflection_Module_InternalGetTypes): New icall.
2634
2635 2003-11-08  Martin Baulig  <martin@ximian.com>
2636
2637         * class.c (mono_class_inflate_generic_method): Interface method
2638         don't have a header.
2639
2640         * reflection.c (mono_image_get_methodspec_token): Take an
2641         additional `MonoGenericInst *' argument instead of reading it from
2642         the header; this is necessary to support interfaces.
2643         (mono_image_create_token): Pass the `MonoGenericInst *' from the
2644         MonoReflectionInflatedMethod to mono_image_get_methodspec_token().
2645         (inflated_method_get_object): Take an additional `MonoGenericInst *'
2646         argument.
2647
2648         * reflection.h (MonoReflectionInflatedMethod): Added
2649         `MonoGenericInst *ginst'.
2650
2651 2003-11-07  Zoltan Varga  <vargaz@freemail.hu>
2652
2653         * gc.c (mono_domain_finalize): Fix compilation for no GC case.
2654
2655 2003-11-06  Zoltan Varga  <zovarga@ws-zovarga2>
2656
2657         * appdomain.c (mono_domain_unload): Add a workaround for bug #27663.
2658
2659 2003-11-06  Zoltan Varga  <vargaz@freemail.hu>
2660
2661         * reflection.c 
2662         (reflection_methodbuilder_from_method_builder):
2663         (reflection_methodbuilder_from_ctor_builder): New helper functions to 
2664         initialize a ReflectionMethodBuilder structure.
2665         (mono_image_get_methodbuilder_token):
2666         (mono_image_get_ctorbuilder_token): New functions to emit memberref
2667         tokens which point to types in another module inside the same assembly.
2668
2669         * reflection.c: Use the new helper functions.
2670         
2671         * reflection.c (mono_image_basic_init): Initialize basedir and culture.
2672
2673         * icall.c loader.c reflection.c: Use ModuleBuilder->dynamic_image 
2674         instead of AssemblyBuilder->dynamic_assembly in the appropriate places.
2675
2676         * reflection.c (resolution_scope_from_image): Emit a moduleref if
2677         neccesary.
2678
2679         * reflection.c (mono_image_build_metadata): Emit metadata only for the
2680         current module. Emit the manifest only for the main module.
2681
2682         * reflection.c (mono_image_create_token): Add assertion when a 
2683         memberref needs to be created.
2684
2685         * reflection.c reflection.h (MonoDynamicAssembly): Remove unused fields.
2686
2687         * reflection.c (mono_reflection_get_custom_attrs_blob): Allocate a 
2688         larger buffer for the custom attribute blob. Fixes #50637.
2689         
2690 2003-11-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
2691
2692         * threadpool.c: notify listener on async processing handles after
2693         invoking the async callback. Thanks to Zoltan.
2694
2695 2003-11-03  Zoltan Varga  <vargaz@freemail.hu>
2696
2697         * reflection.c (create_dynamic_mono_image): Call mono_image_init to 
2698         avoid code duplication.
2699
2700         * reflection.h (MonoDynamicImage): New type which is currently unused,
2701         but will be used through the ref.emit code in place of 
2702         MonoDynamicAssembly.
2703
2704         * reflection.h (MonoReflectionAssemblyBuilder): Track changes to the
2705         object layout.
2706
2707         * reflection.c (create_dynamic_mono_image): Rewrote so it now creates
2708         a MonoDynamicImage instead of just a MonoImage.
2709         
2710         * reflection.h reflection.c icall.c: Move nearly all AssemblyBuilder
2711         icalls to ModuleBuilder but keep their semantics, so they will work
2712         with moduleb->assemblyb. This will change later.
2713         
2714 2003-11-03  Zoltan Varga  <vargaz@freemail.hu>
2715
2716         * reflection.h (MonoReflectionAssemblyBuilder): Track changes to the
2717         object layout.
2718
2719         * reflection.c (mono_image_build_metadata): Avoid creation of a default
2720         main module, since it is now done by the managed code.
2721
2722 2003-11-03  Martin Baulig  <martin@ximian.com>
2723
2724         * reflection.c (mono_reflection_inflate_method_or_ctor): Set
2725         `ginst->klass' here.
2726         (method_encode_methodspec): Don't use the `ginst->generic_method's
2727         klass if it's a generic instance, use `ginst->klass' in this case.
2728
2729 2003-11-03  Martin Baulig  <martin@ximian.com>
2730
2731         * reflection.c (mono_image_get_generic_method_param_info):
2732         Removed, use mono_image_get_generic_param_info() instead.
2733         (mono_image_get_type_info): Write the GenericParam table before
2734         the Method table.  This is neccessary because in the GenericParam
2735         table, type parameters of the class (ie. '!0' etc.) must come
2736         before the ones from its generic methods (ie. '!!0' etc).
2737
2738 2003-11-03  Zoltan Varga  <vargaz@freemail.hu>
2739
2740         * icall.c (ves_icall_System_Reflection_Assembly_FillName): Fill out AssemblyName->codebase. Fixes #50469.
2741
2742 2003-11-02  Martin Baulig  <martin@ximian.com>
2743
2744         * reflection.c (create_generic_typespec): Take a
2745         `MonoReflectionTypeBuilder *' instead of a `MonoType *' and get
2746         the generic parameters from it.
2747
2748 2003-11-02  Martin Baulig  <martin@ximian.com>
2749
2750         * reflection.c (fieldref_encode_signature): Take a `MonoType *'
2751         instead of a `MonoClassField *' since we just need the type.
2752         (create_generic_typespec): New static function.  Creates a
2753         TypeSpec token for a generic type declaration.
2754         (mono_image_get_generic_field_token): New static function.
2755         (mono_image_create_token): If we're a FieldBuilder in a generic
2756         type declaration, call mono_image_get_generic_field_token() to get
2757         the token.
2758
2759 2003-11-02  Martin Baulig  <martin@ximian.com>
2760
2761         * reflection.h
2762         (MonoReflectionInflatedMethod, MonoReflectionInflatedField): Added
2763         `MonoReflectionGenericInst *declaring_type' and
2764         `MonoReflectionGenericInst *reflected_type' fields.
2765
2766         * reflection.c (mono_reflection_inflate_method_or_ctor): Take a
2767         `MonoReflectionGenericInst *declaring_type' and a
2768         `MonoReflectionGenericInst *reflected_type' argument instead of a
2769         single `MonoReflectionGenericInst *type' one.  Set
2770         `res->declaring_type' and `res->reflected_type' from them.
2771         (mono_reflection_inflate_field): Likewise.      
2772
2773 2003-11-02  Martin Baulig  <martin@ximian.com>
2774
2775         * class.c (mono_class_setup_vtable): Don't store generic methods
2776         in the vtable.  
2777
2778 2003-11-02  Martin Baulig  <martin@ximian.com>
2779
2780         * reflection.h (MonoReflectionGenericInst): Added
2781         `MonoReflectionType *declaring_type'.
2782
2783         * reflection.c (mono_reflection_bind_generic_parameters): Use
2784         `if (tb->parent)' instead of `klass->parent'.
2785
2786 2003-11-01  Zoltan Varga  <vargaz@freemail.hu>
2787
2788         * assembly.c (mono_assembly_open): Avoid crash if a module is loaded
2789         with an empty ASSEMBLY table.
2790
2791         * reflection.c (mono_image_build_metadata): Avoid using the same loop
2792         variable in the inner and outer loops.
2793
2794 2003-10-31  Zoltan Varga  <vargaz@freemail.hu>
2795
2796         * metadata.h (mono_metadata_make_token): Put parentheses around macro
2797         argument.
2798
2799         * appdomain.h appdomain.c (ves_icall_System_AppDomain_InternalPushDomainRef): Fix signature.
2800         
2801         * appdomain.c appdomain.h icall.c: Get rid of the InvokeInDomain 
2802         icalls. Instead, do everything in managed code. This is needed since
2803         it is hard to restore the original domain etc. in unmanaged code in the
2804         presence of undeniable exceptions.
2805
2806         * appdomain.c (ves_icall_System_AppDomain_InternalPushDomainRef): 
2807         New icalls to push and pop appdomain refs.
2808
2809 2003-10-31  Martin Baulig  <martin@ximian.com>
2810
2811         * class.c (inflate_generic_type): Renamed to
2812         mono_class_inflate_generic_type() and made it public.
2813
2814         * icall.c ("System.Reflection.MonoGenericInst::inflate_field"):
2815         New interncall.
2816
2817         * loader.c (mono_field_from_memberref): Also set the retklass for
2818         typespecs.
2819
2820         * fielder.c (mono_image_get_inflated_field_token): New static
2821         method; creates a metadata token for an inflated field.
2822         (mono_image_create_token, fixup_method): Added support for
2823         "MonoInflatedField".
2824         (fieldbuilder_to_mono_class_field): New static function.
2825         (mono_reflection_inflate_field): New public function.
2826
2827         * reflection.h
2828         (MonoReflectionGenericInst): Added `MonoArray *fields'.
2829         (MonoReflectionInflatedField): New typedef.     
2830
2831 2003-10-30  Bernie Solomon  <bernard@ugsolutions.com>
2832
2833         * socket-io.c (in6_addr ipaddress_to_struct_in6_addr): fix
2834         for Solaris and other platforms without s6_addr16
2835
2836 2003-10-30  Martin Baulig  <martin@ximian.com>
2837
2838         * class.c (inflate_generic_type): Take just one `MonoGenericInst *'
2839         argument instead of two.
2840         (mono_class_inflate_generic_signature): Likewise.
2841         (inflate_generic_header): Likewise.
2842         (mono_class_inflate_generic_method): Likewise.  In addition, if
2843         `ginst->klass' is set, it becomes the new `method->klass'.
2844
2845         * class.h (MonoGenericInst): Removed the `gpointer mbuilder'
2846         field.
2847
2848         * reflection.c (encode_generic_method_sig): Write a 0xa as the
2849         first byte. [FIXME]
2850         (method_encode_methodspec): If we have generic parameters, create
2851         a MethodSpec instead of a MethodRef.
2852         (fixup_method): Added support for "MonoInflatedMethod" and
2853         "MonoInflatedCtor".
2854         (mono_image_create_token): Added support for "MonoInflatedMethod"
2855         and "MonoInflatedCtor".
2856         (inflated_method_get_object): New static function; returns a
2857         managed "System.Reflection.MonoInflatedMethod" object.
2858         (mono_reflection_bind_generic_method_parameters): Return a
2859         `MonoReflectionInflatedMethod' instead of a `MonoReflectionMethod'.
2860         (mono_reflection_inflate_method_or_ctor): Likewise.
2861         (mono_image_get_generic_method_param_info): Initialize unused
2862         fields to zero.
2863         (mono_image_get_generic_param_info): Likewise.
2864
2865         * reflection.h (MonoReflectionInflatedMethod): New public
2866         typedef.  Corresponds to the managed "S.R.MonoInflatedMethod" and
2867         "S.R.MonoInflatedCtor" classes.
2868
2869         * loader.c (method_from_memberref): If we're a TypeSpec and it
2870         resolves to a generic instance, inflate the method.
2871
2872 2003-10-28  Dick Porter  <dick@ximian.com>
2873
2874         * object.c (mono_runtime_run_main): Convert command-line arguments
2875         into utf8, falling back to the user's locale encoding to do so.
2876
2877 2003-10-27  Zoltan Varga  <vargaz@freemail.hu>
2878
2879         * loader.c (mono_get_method_from_token): Avoid looking up the icalls
2880         at this time.
2881
2882         * marshal.c (mono_marshal_get_native_wrapper): Lookup icalls here.
2883
2884         * reflection.c (reflection_methodbuilder_to_mono_method): Avoid looking
2885         up icalls at method definition time. Partially fixes #33569.
2886
2887 2003-10-25  Zoltan Varga  <vargaz@freemail.hu>
2888
2889         * marshal.c (mono_marshal_get_native_wrapper): Add support for [Out]
2890         marshalling of arrays. Fixes #50116.
2891
2892         * appdomain.c (ves_icall_System_AppDomain_InternalIsFinalizingForUnload): New icall.
2893
2894         * appdomain.c (unload_thread_main): Clear class->cached_vtable if it
2895         points to a vtable in the dying appdomain.
2896
2897         * appdomain.c (mono_domain_unload): Move the notification of OnUnload
2898         listeners into unmanaged code inside the lock.
2899
2900         * object.c (mono_class_vtable): Turn off typed allocation in non-root
2901         domains and add some comments.
2902
2903 2003-10-25  Martin Baulig  <martin@ximian.com>
2904
2905         * class.h (MonoGenericInst): Added `MonoClass *klass' field.
2906
2907         * image.h (MonoImage): Added `GHashTable *typespec_cache'.
2908
2909         * metadata.c (mono_metadata_parse_generic_inst): Renamed to
2910         `do_mono_metadata_parse_generic_inst'; pass it the MonoType we're
2911         currently parsing.  Create the generic class and store it in
2912         `generic_inst->klass' before parsing the type arguments.  This is
2913         required to support "recursive" definitions; see mcs/tests/gen-23.cs
2914         for an example.
2915         (mono_type_create_from_typespec): Use a new `image->typespec_cache'
2916         to support recursive typespec entries.
2917
2918         * class.c (mono_class_setup_parent): If our parent is a generic
2919         instance, we may get called before it has its name set.
2920         (mono_class_from_generic): Splitted into
2921         mono_class_create_from_generic() and mono_class_initialize_generic().
2922
2923 2003-10-25  Martin Baulig  <martin@ximian.com>
2924
2925         * icall.c (ves_icall_Type_BindGenericParameters): Return a
2926         `MonoReflectionGenericInst *' instead of a `MonoReflectionType *'.
2927         ("System.Reflection.MonoGenericInst::inflate_method"): New interncall.
2928         ("System.Reflection.MonoGenericInst::inflate_ctor"): New interncall.
2929
2930         * reflection.c (my_mono_class_from_mono_type): Added MONO_TYPE_GENERICINST.
2931         (create_typespec): Likewise.
2932         (mono_reflection_bind_generic_parameters): Return a
2933         `MonoReflectionGenericInst *' instead of a `MonoClass *'.
2934         (mono_reflection_inflate_method_or_ctor): New public function.
2935
2936         * reflection.h (MonoReflectionGenericInst): New typedef.        
2937
2938 2003-10-24  Zoltan Varga  <vargaz@freemail.hu>
2939
2940         * object.c (mono_class_proxy_vtable): Run the whole vtable construction
2941         inside the domain lock. Fixes #49993.
2942         
2943         * object.c (mono_class_vtable): When typed allocation is used, 
2944         allocate vtables in the GC heap instead of in the mempool, since the
2945         vtables contain GC descriptors which are used by the collector even
2946         after the domain owning the mempool is unloaded.
2947
2948         * domain.c (mono_domain_set): Rename to mono_domain_set_internal.
2949
2950         * domain.c (mono_domain_unload): Rename to mono_domain_free to better
2951         reflect what it does. Also invalidate mempools instead of freeing
2952         them if a define is set.
2953
2954         * appdomain.h (MonoAppDomainState): New enumeration to hold the state
2955         of the appdomain.
2956         
2957         * appdomain.h (_MonoDomain): New field 'finalizable_object_hash' to
2958         hold the finalizable objects in this domain.
2959
2960         * appdomain.h (_MonoDomain): New field 'state' to hold the state of the
2961         appdomain.
2962
2963         * appdomain.c (mono_domain_set): New function to set the current
2964         appdomain, but only if it is not being unloaded.
2965
2966         * appdomain.c threads.c threadpool.c object.c: Avoid entering an
2967         appdomain which is being unloaded.
2968         
2969         * appdomain.c (ves_icall_System_AppDomain_InternalUnload): Prevent
2970         unloading of the root appdomain.
2971
2972         * appdomain.c (ves_icall_System_AppDomain_InternalInvokeInDomain): New
2973         icall to execute a method in another appdomain. Intended as a 
2974         replacement for InternalSetDomain, which can confuse the code 
2975         generation in the JIT.
2976
2977         * appdomain.c (mono_domain_is_unloading): New function to determine
2978         whenever an appdomain is unloading.
2979
2980         * appdomain.c (mono_domain_unload): New function to correctly unload
2981         an appdomain.
2982
2983         * assembly.c (mono_assembly_load_references): Check that an assembly
2984         does not references itself.
2985
2986         * gc.c (mono_domain_finalize): Rewrote so instead of finalizing a
2987         domain manually, it asks the finalizer thread to do it, then waits for
2988         the result. Also added a timeout.
2989
2990         * icall.c: Register the new icalls.
2991
2992         * threads.h threads.c: Export the mono_gc_stop_world and 
2993         mono_gc_start_world functions.
2994         
2995         * mempool.h mempool.c (mono_mempool_invalidate): New debugging 
2996         function to fill out the mempool with 0x2a.
2997
2998 2003-10-22  Zoltan Varga  <vargaz@freemail.hu>
2999
3000         * reflection.h (MonoReflectionMethodAux): New structure to store
3001         information which is rarely used, thus is not in the MonoMethod
3002         structure.
3003
3004         * reflection.h (MonoDynamicAssembly): New field 'method_aux_hash' to
3005         store the aux info.
3006
3007         * reflection.c (mono_methodbuilder_to_mono_method): Store param names
3008         and marshalling info into the aux structure.
3009
3010         * loader.c (mono_method_get_marshal_info): Retrieve the marshal info
3011         from the aux structure.
3012
3013         * loader.c (mono_method_get_param_names): Retrieve the param names from
3014         the aux structure.
3015         
3016 2003-10-21  Zoltan Varga  <vargaz@freemail.hu>
3017
3018         * exception.h exception.c: Add AppDomainUnloadedException && fix 
3019         warning.
3020
3021 2003-10-21  Dick Porter  <dick@ximian.com>
3022
3023         * socket-io.c
3024         (ves_icall_System_Net_Sockets_Socket_Select_internal): Applied
3025         patch from Laramie Leavitt moving divide out of loop. (Bug 45381).
3026
3027 2003-10-21  Martin Baulig  <martin@ximian.com>
3028
3029         * reflection.c (mono_reflection_bind_generic_parameters):
3030         `klass->parent' is NULL for interfaces.
3031
3032 2003-10-21  Martin Baulig  <martin@ximian.com>
3033
3034         * reflection.c (create_typespec): Added MONO_TYPE_VAR and MONO_TYPE_MVAR.
3035
3036 2003-10-20  Zoltan Varga  <vargaz@freemail.hu>
3037
3038         * exception.c (mono_exception_from_name_msg): New helper function for
3039         creating exceptions and initializing their message field.
3040
3041         * exception.c: Simplify functions using the new helper.
3042
3043         * exception.h exception.c (mono_get_exception_cannot_unload_appdomain):
3044         New function.
3045
3046         * object.h object.c: Remove G_GNUC_NORETURN from the signature of
3047         mono_raise_exception, since otherwise gcc doesn't generate the function
3048         epilog for raise_exception, confusing the stack unwinding in the JIT.
3049         Fixes #45043.
3050
3051         * rawbuffer.c (mono_raw_buffer_load_mmap): Map mmap-ed memory with
3052         PROT_EXEC. This seems to prevent segmentation faults on Fedora Linux.
3053         Fixes #49499.
3054
3055 2003-10-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3056
3057         * icall.c: OutputDebugStringW expects 16-bit unicode characters, not
3058         utf8.
3059
3060 2003-10-18  Lluis Sanchez Gual  <lluis@ximian.com>
3061
3062         * icall.c: Removed GetUninitializedObject method because
3063           AllocateUninitializedClassInstance does the same.
3064
3065 2003-10-18  Martin Baulig  <martin@ximian.com>
3066
3067         * class.c (inflate_generic_signature): Renamed to
3068         mono_class_inflate_generic_signature() and made it public.
3069         (my_mono_class_from_generic_parameter): New static function; if we
3070         don't already have the generic parameter's MonoClass, create a
3071         very simple one which is just used internally in the runtime and
3072         not passed back to managed code.
3073
3074         * class.h (MonoGenericInst): Added `gpointer mbuilder' field.
3075
3076         * metadata.h (MonoMethodSignature): Moved the
3077         `MonoGenericParam *gen_params' to the MonoMethodHeader.
3078         (MonoMethodHeader): Moved the `MonoGenericParam *gen_params' here.
3079
3080         * icall.c (ves_icall_MethodInfo_GetGenericArguments): Renamed to
3081         ves_icall_MonoMethod_GetGenericArguments(); this is now an
3082         interncall on the MonoMethod class, not on MethodInfo.
3083         (ves_icall_MethodInfo_BindGenericParameters): Removed, we're now
3084         calling mono_reflection_bind_generic_method_parameters() directly.
3085
3086         * loader.c (mono_method_get_signature): If this is a MethodSpec;
3087         return the already computed `method->signature'.
3088         (method_from_methodspec): New static function to load a method
3089         from a MethodSpec entry.
3090         (mono_get_method_from_token): Call the new method_from_methodspec()
3091         for MethodSpec tokens.  
3092         (mono_get_method_from_token): If we're a generic method, load the
3093         type parameters.
3094
3095         * reflection.c (mono_image_get_memberref_token): Allow
3096         MEMBERREF_PARENT_TYPEDEF here; this will be used in the MethodSpec
3097         table.
3098         (fixup_method): Added support for MONO_TABLE_METHODSPEC.
3099         (mono_image_create_token): First check whether it's a generic
3100         method (so we'd need to create a MethodSpec), then do the other
3101         two alternatives.
3102         (mono_reflection_bind_generic_method_parameters): Return a
3103         `MonoReflectionMethod *' instead of a `MonoMethod *'; we're now
3104         called directly from the interncall.
3105
3106 2003-10-17  Zoltan Varga  <vargaz@freemail.hu>
3107
3108         * reflection.c (load_public_key): Move loading of the public key
3109         into managed code.
3110
3111         * image.h (MonoAssemblyName): Add public_key and hash_alg fields.
3112
3113         * assembly.c (mono_assembly_open): Fill in public_key and hash_alg
3114         fields.
3115
3116         * icall.c (ves_icall_System_Reflection_Assembly_FillName): Fill in
3117         culture, hash_alg and public_key. Fixes #49555.
3118
3119 2003-10-17  Martin Baulig  <martin@ximian.com>
3120
3121         * class.h (MonoGenericInst): Moved this declaration here and added
3122         `MonoMethod *generic_method'.
3123
3124         * icall.c
3125         (ves_icall_MethodInfo_GetGenericArguments): New interncall.
3126         (ves_icall_MethodInfo_BindGenericParameters): New interncall.
3127
3128         * metadata.c (mono_metadata_type_equal): Two types of
3129         MONO_TYPE_VAR or MONO_TYPE_MVAR equals if they have the same
3130         index; ie. don't compare the address of the `MonoGenericParam'
3131         structure.
3132         (mono_metadata_load_generic_params): Removed the `MonoMethod
3133         *method' argument.
3134
3135         * metadata.h (MonoGenericInst): Moved declaration to class.h.
3136         (MonoMethodHeader): Added `MonoGenericInst *geninst'.
3137
3138         * reflection.c (method_encode_signature): Encode the number of
3139         generic parameters.
3140         (encode_generic_method_sig): New static function.
3141         (method_encode_methodspec): New static function; creates an entry
3142         in the MethodSpec table for a generic method.
3143         (mono_image_get_methodspec_token): New static function.
3144         (mono_image_create_token): Call mono_image_get_methodspec_token()
3145         for generic methods.
3146         (mono_reflection_bind_generic_method_parameters): New public
3147         function.  Instantiates a generic method.
3148
3149 2003-10-16  Martin Baulig  <martin@ximian.com>
3150
3151         * metadata.h (MonoMethodSignature): Moved `MonoGenericParam
3152         *gen_params' here from MonoMethodHeader.
3153
3154         * metadata.c (mono_metadata_parse_method_signature): If we have
3155         generic parameters, initialize `method->gen_params' and then set
3156         the correct `type->data.generic_param' in all the parameters.
3157
3158 2003-10-16  Zoltan Varga  <vargaz@freemail.hu>
3159
3160         * threads.c (mono_threads_get_default_stacksize): New function to 
3161         return the default stacksize.
3162
3163         * gc.c (mono_gc_cleanup): Use a separate event for waiting for the
3164         termination of the finalizer thread, since the previous method had
3165         race conditions. Fixes #49628.
3166
3167         * gc.c (mono_gc_init): Use the same stacksize for the finalizer thread
3168         as for the other managed threads.
3169
3170 2003-10-16  Martin Baulig  <martin@ximian.com>
3171
3172         * class.c (inflate_generic_signature): Copy `generic_param_count'
3173         and `gen_params'.
3174
3175         * icall.c (ves_icall_MethodInfo_get_IsGenericMethodDefinition):
3176         New interncall.
3177
3178         * metadata.c (mono_metadata_parse_method_signature): Actually set
3179         the `method->generic_param_count' here.
3180         (mono_metadata_load_generic_params): Initialize `pklass' to NULL.
3181
3182 2003-10-15  Zoltan Varga  <vargaz@freemail.hu>
3183
3184         * object.h: Add a new field to TypedRef to simplify the implementation
3185         of the REFANY opcodes in the JIT.
3186
3187         * icall.c: Make use of the new field.
3188
3189         * metadata.c (mono_type_size): Compute the size of TYPEDBYREF types
3190         dynamically.
3191
3192 2003-10-15  Martin Baulig  <martin@ximian.com>
3193
3194         * class.c (mono_class_from_gen_param): Renamed to
3195         mono_class_from_generic_parameter() and moved most of the
3196         functionality from mono_reflection_define_generic_parameter()
3197         here; ie. we create a "real" class here.
3198         (mono_class_from_mono_type): Only allow MONO_TYPE_VAR and
3199         MONO_TYPE_MVAR if mono_class_from_generic_parameter() has
3200         previously been called.
3201
3202         * class.h (MonoGenericParam): Moved the declaration of this struct
3203         here from metadata.h and added `MonoMethod *method'.
3204
3205         * icall.c (ves_icall_MonoType_get_DeclaringMethod): New
3206         interncall.
3207
3208         * loader.c (mono_get_method_from_token): If we have any generic
3209         parameters, call mono_metadata_load_generic_params() to read them
3210         from the MONO_TABLE_GENERICPAR.
3211
3212         * metadata.c (mono_metadata_load_generic_params): Added
3213         `MonoMethod *method' argument which is used MONO_TYPE_MVAR.
3214
3215         * metadata.h (MonoMethodSignature): Replaced
3216         `MonoGenericInst *geninst' with `guint16 generic_param_count'.
3217         (MonoMethodHeader): Added `MonoGenericParam *gen_params'.
3218
3219         * reflection.c (mono_reflection_define_generic_parameter): Moved
3220         most of the functionality into the new
3221         mono_class_from_generic_parameter(); set the `method' field if
3222         we're a method parameter.       
3223
3224 2003-10-13 Bernie Solomon  <bernard@ugsolutions.com>
3225
3226         * marshal.c (emit_struct_conv): if native size is 0
3227         emit no code.
3228
3229 2003-10-14  Martin Baulig  <martin@ximian.com>
3230
3231         * icall.c: The generics API has changed in the spec since it was
3232         added to System.Type; these modifications make it match the spec
3233         again.
3234         (ves_icall_Type_GetGenericParameters): Renamed to
3235         `ves_icall_Type_GetGenericArguments'.
3236         (ves_icall_Type_get_IsGenericTypeDefinition): New interncall.
3237         (ves_icall_MonoType_get_HasGenericParameteres): Renamed to
3238         `ves_icall_MonoType_get_HasGenericArguments'.
3239         (ves_icall_MonoType_get_IsUnboundGenericParameter): Renamed to
3240         `ves_icall_MonoType_get_IsGenericParameter'.
3241         (ves_icall_MonoType_get_HasUnboundGenericParameters): Removed;
3242         this is no interncall anymore.
3243         (ves_icall_TypeBuilder_get_IsUnboundGenericParameter): Renamed to
3244         `ves_icall_TypeBuilder_get_IsGenericParameter'.
3245
3246 2003-10-14  Martin Baulig  <martin@ximian.com>
3247
3248         * reflection.c (mono_reflection_bind_generic_parameters): Also
3249         inflate generic methods if we're reading the class from IL.
3250
3251 2003-10-13  Martin Baulig  <martin@ximian.com>
3252
3253         * reflection.c (mono_reflection_define_generic_parameter): This
3254         method isn't called directly from the icall anymore; take a
3255         `MonoReflectionAssemblyBuilder *' so we can use this for type and
3256         method generic parameters.
3257         (ReflectionMethodBuilder): Added `MonoArray *generic_param'.
3258         (method_builder_encode_signature): Encode generic parameters.
3259         (mono_image_get_method_info): Write generic params to the
3260         MONO_TABLE_GENERICPARAM table.
3261
3262         * reflection.h (MonoReflectionMethodBuilder): Added
3263         `MonoArray *generic_params'.
3264
3265         * metadata.h (MonoMethodSignature): Added `MonoGenericInst *geninst'.
3266
3267         * icall.c (ves_icall_TypeBuilder_define_generic_parameter): Added
3268         wrapper for mono_reflection_define_generic_parameter().
3269         (ves_icall_MethodBuilder_define_generic_parameter): Likewise.   
3270
3271 2003-10-13  Zoltan Varga  <vargaz@freemail.hu>
3272
3273         * marshal.h: Add missing function to fix build.
3274
3275         * marshal.c (mono_marshal_get_native_wrapper): Add support for 
3276         the SetLastError pinvoke attribute.
3277
3278         * marshal.c (mono_marshal_set_last_error): New helper function called
3279         by the generated code.
3280         
3281         * marshal.c (mono_mb_emit_branch): New helper function.
3282
3283         * marshal.c (mono_mb_emit_exception): Added exception name parameter.
3284
3285         * marshal.c (mono_marshal_get_managed_wrapper): Added support for
3286         classes as parameters and return values of delegates. Fixes #29256. 
3287
3288 2003-10-12  Bernie Solomon  <bernard@ugsolutions.com>
3289
3290         * locales.c: use gint32 in non HAVE_ICU case
3291
3292 2003-10-11  Martin Baulig  <martin@ximian.com>
3293
3294         * mono-debug.c (mono_debug_add_method): Added a workaround for
3295         bug #48591.
3296
3297 2003-10-10  Zoltan Varga  <vargaz@freemail.hu>
3298
3299         * marshal.c (mono_marshal_get_managed_wrapper): Under windows,
3300         delegates passed to native code must use the STDCALL calling 
3301         convention. Fixes #35987.
3302
3303 2003-10-10  Martin Baulig  <martin@ximian.com>
3304
3305         * class.c (inflate_generic_type): If we're inflating for a generic
3306         type instance (and not for a generic method), return
3307         MONO_TYPE_MVAR unchanged.
3308
3309 2003-10-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3310
3311         * string-icalls.c: Join ignores null strings in the source array.
3312         * threadpool.[ch]: export busy_worker_threads, not mono_worker_threads.
3313         * threads.c: GetAvailableTheads is slightly more accurate.
3314
3315 2003-10-09  Bernie Solomon  <bernard@ugsolutions.com>
3316
3317         * threads.h threads.c : add mono_threads_set_default_stacksize
3318         and pass default to CreateThread calls.
3319
3320 2003-10-09  Dick Porter  <dick@ximian.com>
3321
3322         * icall.c:
3323         * locales.h:
3324         * locales.c: Internal calls for constructing CultureInfo and
3325         related objects from libicu (if its available.)
3326
3327 2003-10-09  Zoltan Varga  <vargaz@freemail.hu>
3328
3329         * debug-helpers.c (wrapper_type_names): Add 'unknown' wrapper type.
3330
3331 2003-10-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3332
3333         * threadpool.c: added an argument to async_invoke_thread that is the
3334         item to process, pass the MonoAsyncResult to the thread start function
3335         when creating a new thread. This way we don't need to acquire any lock
3336         when we're creating a new thread. Readded a semaphore for faster
3337         response times (instead of that Sleep i added).
3338
3339 2003-10-08  Bernie Solomon  <bernard@ugsolutions.com>
3340
3341         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData):
3342         get daylight change dates better on Windows, fix handling
3343         of platforms without tm_gmtoff.
3344
3345 2003-10-06  Martin Baulig  <martin@ximian.com>
3346
3347         * class.c (inflate_generic_method): Renamed to
3348         mono_class_inflate_generic_method() and made public.
3349         (mono_class_init): Don't inflate the generic methods here.
3350         (mono_class_from_generic): Added `gboolean inflate_methods'
3351         argument.  Inflate the methods here.
3352
3353         * loader.c (mono_method_get_param_names): Ignore instances of
3354         generic types for the moment.
3355
3356         * reflection.c (fixup_method): Added support for inflated methods.
3357         (mono_image_create_token): Use mono_image_get_methodref_token()
3358         for inflated methods.
3359         (mono_custom_attrs_from_param): Ignore instances of generic types
3360         for the moment.
3361         (mono_reflection_bind_generic_parameters): New public function.
3362         Moved all the functionality from
3363         ves_icall_Type_BindGenericParameters() here and added support for
3364         dynamic types.
3365         (mono_reflection_define_generic_parameter): Initialize
3366         `klass->methods' here.
3367
3368         * icall.c (ves_icall_Type_BindGenericParameters): Moved all the
3369         functionality into mono_reflection_define_generic_parameter().
3370         (ves_icall_Type_GetGenericTypeDefinition): If we're coming from a
3371         TypeBuilder, return that TypeBuilder.
3372
3373 2003-10-08  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3374
3375         * appdomain.c: removed mono_delegate_semaphore.
3376
3377         * threadpool.c:
3378         (mono_thread_pool_add): moved hash table creation inside and the thread 
3379         creation outside of the critical region.
3380         (mono_thread_pool_finish): removed obsolete code.
3381         (async_invoke_thread): don't use the semaphore. Use a plain Sleep and
3382         continue or exit the thread depending on the queue.
3383
3384 2003-10-07  Bernie Solomon  <bernard@ugsolutions.com>
3385
3386         * metadata.c (mono_type_to_unmanaged): allow bools to marshal as I1
3387         marshal.c (emit_ptr_to_str_conv & mono_marshal_get_native_wrapper):
3388         handle more bool marshalling options
3389
3390 2003-10-07  Zoltan Varga  <vargaz@freemail.hu>
3391
3392         * marshal.c (mono_marshal_get_native_wrapper): Fix marshalling of
3393         arrays of structs. Also add a more descriptive error message when
3394         a structure member is marshalled as LPArray.
3395
3396 2003-10-06  Zoltan Varga  <vargaz@freemail.hu>
3397
3398         * marshal.c (mono_marshal_get_native_wrapper): Add support for
3399         marshalling arrays of complex types. Fixes #29098. Also remove an
3400         usused and incomplete function.
3401
3402 Mon Oct 6 15:38:40 CEST 2003 Paolo Molaro <lupus@ximian.com>
3403
3404         * gc.c: report heap_size - free_bytes as total memory allocated
3405         (bug#49362).
3406
3407 2003-10-05  Zoltan Varga  <vargaz@freemail.hu>
3408
3409         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData): Finally 
3410         fix timezone handling problems on Windows.
3411         
3412         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData): Avoid
3413         asserts when the year is outside the range handled by ms the functions.
3414
3415         * class.c (setup_interface_offsets): If the class is an interface,
3416         fill out its interface_offsets slot.
3417
3418 2003-10-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3419
3420         * threadpool.c: mark threadpool threads as background.
3421
3422 2003-10-03  Bernie Solomon  <bernard@ugsolutions.com>
3423
3424         * decimal.c - define DECINLINE to nothing if not using GCC
3425
3426 2003-10-03  Zoltan Varga  <vargaz@freemail.hu>
3427
3428         * assembly.c: More refcount fixes.
3429
3430 2003-10-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3431
3432         * string-icalls.c: if we're not trimming, return the same string.
3433         When not splitting, don't create a new string.
3434
3435 2003-10-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3436
3437         * image.c:
3438         (mono_image_open): increment the ref_count inside the critical section.
3439
3440 2003-10-02  Zoltan Varga  <vargaz@freemail.hu>
3441
3442         * image.c (mono_image_open): Fix reference counting bug.
3443
3444 2003-09-30  Bernie Solomon  <bernard@ugsolutions.com>
3445
3446         * marshal.c (mono_marshal_type_size) struct alignment changed for 
3447         64bit machines.  (emit_ptr_to_str_conv) Fix bool conversions for 
3448         64bits. Avoid leak in mono_marshal_get_native_wrapper when
3449         mono_lookup_pinvoke_call throws.        
3450
3451 2003-09-30  Zoltan Varga  <vargaz@freemail.hu>
3452
3453         * reflection.c (mono_reflection_parse_type): Fix #49114.
3454
3455         * file-io.c (ves_icall_System_IO_MonoIO_GetFileAttributes): Add
3456         temporary workaround for cygwin header problem.
3457
3458         * object.c (mono_object_isinst): Synchronize this with the code
3459         generated by the JIT for casts.
3460
3461 2003-09-29  Zoltan Varga  <vargaz@freemail.hu>
3462
3463         * reflection.c (encode_type): Fix #38332.
3464
3465 2003-09-26  Zoltan Varga  <vargaz@freemail.hu>
3466
3467         * marshal.c (mono_marshal_method_from_wrapper): New function to return
3468         the original method from the wrapper method.
3469
3470 2003-09-25  Martin Baulig  <martin@ximian.com>
3471
3472         * icall.c (ves_icall_Type_IsGenericTypeDefinition): Removed this
3473         interncall since it was identical to `Type.GetGenericTypeDefinition()'.
3474         (ves_icall_Type_get_IsGenericInstance): New interncall.
3475
3476 2003-09-24 Bernie Solomon <bernard@ugsolutions.com>
3477
3478         * object.c: fix cast warning in big endian code.
3479
3480 2003-09-19 Jackson Harper <jackson@latitudegeo.com>
3481
3482         * icall.c: Timezone patch from Zoltan Varga (vargaz@freemail.hu)
3483         
3484 2003-09-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3485
3486         * assembly.c: don't call check_env from mono_assembly_load. It's
3487         already done once in mono_assemblies_init and may cause headaches when
3488         multiple threads are loading assemblies.
3489
3490 2003-09-19  Martin Baulig  <martin@ximian.com>
3491
3492         * reflection.c (mono_reflection_define_generic_parameter): Don't
3493         allocate `klass->methods', set `klass->flags' to
3494         TYPE_ATTRIBUTE_INTERFACE, not TYPE_ATTRIBUTE_ABSTRACT.
3495
3496 2003-09-18  Martin Baulig  <martin@ximian.com>
3497
3498         * class.c (mono_class_init): Don't create `class->methods' if it's
3499         already initialized.
3500
3501         * metadata.c (mono_metadata_load_generic_params): Make this
3502         actually work.
3503
3504         * reflection.c (mono_reflection_define_generic_parameter): Set
3505         parent class and interfaces from the constraints.
3506
3507         * reflection.h (MonoReflectionGenericParam): Added `guint32 flags'
3508         to keep this struct in sync with the declaration in TypeBuilder.cs.
3509
3510 2003-09-17  Martin Baulig  <martin@ximian.com>
3511
3512         * metadata.h (MonoType): Replaced the data's `int type_param'
3513         field with `MonoGenericParam *generic_param'.
3514         (MonoGenericParam): Added `MonoClass *klass'.
3515
3516         * class.c (mono_class_from_gen_param): Removed the
3517         `MonoImage *image' and `int type_num' arguments.
3518
3519         * metadata.c (mono_metadata_parse_generic_param): New static
3520         method; creates a MonoGenericParam which just contains the index.
3521         (do_mono_metadata_parse_type): Call
3522         mono_metadata_parse_generic_param() for MONO_TYPE_VAR and
3523         MONO_TYPE_MVAR.
3524
3525         * reflection.c (mono_image_typedef_or_ref): Generic type
3526         parameters may be in the same assembly, but never use a typedef
3527         for them.
3528         (mono_reflection_define_generic_parameter): We're now creating a
3529         "real" class for the type parameter; it's now safe to call
3530         mono_class_from_mono_type() on the class'es type, it'll do the
3531         right thing.
3532
3533 2003-09-16  Martin Baulig  <martin@ximian.com>
3534
3535         * mono-debug-debugger.c (allocate_symbol_file_entry): Initialize
3536         `symfile->range_entry_size' and `symfile->class_entry_size' here;
3537         the `symfile' data structure must be fully initialized before it
3538         gets added to the table.
3539
3540 2003-09-15  Zoltan Varga  <vargaz@freemail.hu>
3541
3542         * icall.c (ves_icall_Type_IsArrayImpl): Added MONO_ARCH_SAVE_REGS.
3543
3544         * appdomain.h domain.c (MonoDomain): Added new hashtable to store the
3545         class init trampolines.
3546
3547 2003-09-11  Zoltan Varga  <vargaz@freemail.hu>
3548
3549         * profiler.c (mono_profiler_load): Added '-time' and '-alloc' options
3550         to the built-in profiler to turn off time and allocation profiling
3551         respectively.
3552
3553 2003-09-10  Zoltan Varga  <vargaz@freemail.hu>
3554
3555         * profiler.c (mono_profiler_coverage_alloc): Use NULL instead of
3556         g_direct_equal.
3557
3558         * debug-helpers.c (mono_method_full_name): Print the wrapper type
3559         in human readable form.
3560
3561 2003-09-08  Zoltan Varga  <vargaz@freemail.hu>
3562
3563         * reflection.c icall.c: Fixed warnings.
3564
3565         * image.c (load_class_names): Use a temporary hash table to hold the
3566         namespaces in order to avoid doing many string comparisons.
3567
3568         * image.h: Fix typo.
3569
3570         * image.c class.c rawbuffer.c reflection.c threads.c verify.c domain.c:
3571         Pass NULL instead of g_direct_equal to the GHashTable constructor 
3572         since the NULL case is short-circuited inside g_hash_table_lookup, 
3573         leading to better performance.  
3574
3575         * metadata.c (mono_metadata_custom_attrs_from_index): New function to
3576         obtain the first custom attribute for a given index. Depends on the
3577         CustomAttribute table being sorted by the parent field.
3578
3579         * reflection.c (mono_custom_attrs_from_index): Use the new function 
3580         for better performance.
3581
3582 2003-09-07  Martin Baulig  <martin@ximian.com>
3583
3584         * class.c (mono_class_init): If we're a generic instance, inflate
3585         all our methods instead of loading them from the image.
3586         (mono_class_from_generic): Set `class->methods = gklass->methods'.
3587
3588 2003-09-07  Martin Baulig  <martin@ximian.com>
3589
3590         * mono-debug-debugger.c: Added support for constructors.
3591
3592 2003-09-06  Martin Baulig  <martin@ximian.com>
3593
3594         * icall.c (ves_icall_TypeBuilder_get_IsUnboundGenericParameter):
3595         New interncall.
3596
3597         * reflection.c (mono_reflection_setup_generic_class): Call
3598         ensure_runtime_vtable() to create the vtable.
3599
3600 2003-09-05  Martin Baulig  <martin@ximian.com>
3601
3602         * class.c (mono_class_array_element_size): Added MONO_TYPE_VAR and
3603         MONO_TYPE_MVAR.
3604
3605 2003-09-04  Martin Baulig  <martin@ximian.com>
3606
3607         * reflection.c (mono_reflection_define_generic_parameter): Generic
3608         parameters start with zero.
3609
3610 2003-09-04  Martin Baulig  <martin@ximian.com>
3611
3612         * metadata.c (mono_type_size): Added MONO_TYPE_VAR and MONO_TYPE_MVAR.
3613
3614         * reflection.h (MonoReflectionGenericParam): New typedef.
3615         (MonoReflectionTypeBuilder): Added `generic_params' fields to get
3616         the generic parameters from the managed TypeBuilder.
3617
3618         * reflection.c (mono_reflection_define_generic_parameter): New function.
3619         (mono_reflection_create_runtime_class): Encode generic parameters.
3620         (mono_reflection_setup_generic_class): New function; this is
3621         called after adding adding all generic params to the TypeBuilder.
3622         (encode_type): Added MONO_TYPE_VAR.
3623
3624 2003-09-04  Zoltan Varga  <vargaz@freemail.hu>
3625
3626         * class.h class.c (mono_class_needs_cctor_run): Moved this method
3627         here from the JIT.
3628
3629         * assembly.h assembly.c: Moved the AOT loading code into an assembly
3630         load hook.
3631
3632 2003-09-03  Zoltan Varga  <vargaz@freemail.hu>
3633
3634         * reflection.h reflection.c class.h class.c: Delete duplicate 
3635         definition of mono_type_get_name () from reflection.c and export the
3636         one in class.c.
3637
3638         * class.c: Class loading fixes from Bernie Solomon 
3639         (bernard@ugsolutions.com).
3640
3641         * reflection.c: Endianness fixes from Bernie Solomon 
3642         (bernard@ugsolutions.com).
3643         
3644 2003-09-01  Zoltan Varga  <vargaz@freemail.hu>
3645
3646         * assembly.h assembly.c: Define a file format version for AOT
3647         libraries.
3648         
3649         * assembly.c (mono_assembly_open): Fix leaking of MonoImage-s.
3650
3651         * appdomain.h (MonoJitInfo): New field to determine whenever the
3652         code is domain neutral.
3653         
3654 2003-08-31  Miguel de Icaza  <miguel@ximian.com>
3655
3656         * marshal.c (emit_struct_conv): Add MONO_TYPE_CHAR
3657
3658 2003-08-30  Zoltan Varga  <vargaz@freemail.hu>
3659
3660         * icall.c (ves_icall_System_Web_Util_ICalls_get_machine_install_dir): 
3661         (ves_icall_System_Configuration_DefaultConfig_get_machine_config_path):
3662         Avoid caching the result since strings must be domain specific. Fixes
3663         #48050.
3664
3665 2003-08-29  Zoltan Varga  <vargaz@freemail.hu>
3666
3667         * marshal.c (mono_marshal_init): Make this callable multiple times
3668         since it is hard to find a correct place to call it.
3669
3670         * object.c (mono_runtime_class_init): Execute static constructors in
3671         the correct appdomain.
3672
3673         * image.c (build_guid_table): Handle the case when multiple images have
3674         the same GUID.
3675
3676 2003-08-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3677
3678         * icall.c: added a couple of icalls for System.Web.
3679
3680 2003-08-28  Martin Baulig  <martin@ximian.com>
3681
3682         * icall.c (ves_icall_Type_BindGenericParameters): Use
3683         `klass->generic_inst' instead of `&klass->byval_arg' in the
3684         mono_type_get_object() call.  The returned type must be
3685         MONO_TYPE_GENERICINST and not MONO_TYPE_CLASS.
3686
3687 2003-08-27  Zoltan Varga  <vargaz@freemail.hu>
3688
3689         * NOTES: New file.
3690
3691         * object.c (mono_class_proxy_vtable): Make it thread safe.
3692
3693         * pedump.c: Fix warning.
3694
3695         * object.c appdomain.h: Get rid of metadata_section. 
3696         It is no longer needed and it was causing deadlocks with domain->lock.
3697
3698         * appdomain.c (add_assemblies_to_domain): Make it thread safe.
3699
3700 2003-08-26  Martin Baulig  <martin@ximian.com>
3701
3702         * pedump.c (main): Don't call mono_image_close() if `verify_pe'.
3703
3704 2003-08-26  Martin Baulig  <martin@ximian.com>
3705
3706         * pedump.c (main): Call mono_metadata_init(),
3707         mono_raw_buffer_init(), mono_images_init(), mono_assemblies_init()
3708         and mono_loader_init().
3709
3710 2003-08-26  Zoltan Varga  <vargaz@freemail.hu>
3711
3712         * loader.h: Add missing include to fix build.
3713
3714         * image.h: mono_image_load_references is no more.
3715
3716         * assembly.c: Reworked assembly loading to make it really thread safe.
3717         After these changes, the assembly returned by mono_assembly_open is
3718         fully initialized, i.e. all its references assemblies are loaded.
3719
3720         * assembly.c (mono_image_load_references): Renamed to 
3721         mono_assembly_load_references, and made private, since clients no
3722         longer need to call it.
3723
3724         * class.c: Removed calls to mono_assembly_load_references, since it was
3725         a source of deadlocks.
3726
3727         * loader.h loader.c class.h class.c: Protect data structures using a 
3728         new lock, the loader lock.
3729
3730         * class.c (mono_class_setup_vtable): Create temporary hash tables and
3731         GPtrArrays only when needed.
3732
3733         * class.c (mono_class_layout_fields): Ignore the dummy field inserted 
3734         into empty structures by mcs. Fixes pinvoke7.cs.
3735         
3736         * domain.c (mono_init): Call a new initialization function.
3737
3738         * appdomain.c (mono_runtime_init): Call the new initializer function
3739         of the marshal module.
3740
3741         * marshal.c (mono_marshal_load_type_info): Ignore the dummy field
3742         inserted into empty structures by mcs. Fixes pinvoke7.cs.
3743
3744         * marshal.h marshal.c: Added locks around the wrapper caches to make
3745         this module thread safe.
3746
3747         * icall.c (ves_icall_InternalInvoke): Method wrappers doesn't require a
3748         this argument. Fixes pinvoke1.exe.
3749
3750 2003-08-25  Lluis Sanchez <lluis@ximian.com>
3751
3752         * object.h: Added call_type field to MonoMethodMessage and the corresponding
3753         enumeration of values. Removed fields to store remote call output values in
3754         MonoAsyncResult. Not needed any more.
3755         * object.c: Initialize call_type and async_result fields in mono_message_init.
3756         * marshal.c: mono_delegate_begin_invoke(): for proxies, set call_type before
3757         dispatching the message.
3758         mono_delegate_end_invoke (): delegate to the proxy the work of waiting for the
3759         async call to finish. To do it use a message with EndInvoke call type.
3760
3761 2003-08-25  Zoltan Varga  <vargaz@freemail.hu>
3762
3763         * loader.h loader.c (mono_method_hash_marhal_info): New function which
3764         determines whenever a method has marshalling info.
3765
3766 2003-08-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3767
3768         * assembly.c: fix the build on windows.
3769
3770 2003-08-22 Lluis Sanchez <lluis@ximian.com>
3771
3772         * object.cs: Fixed bug #47785.
3773
3774 2003-08-22 Jackson Harper <jackson@latitudegeo.com>
3775
3776         * string-icalls.c (StringReplace): If their are no occurances of
3777         the old string found return a reference to the supplied
3778         string. This saves some memory and matches MS behavoir.
3779         
3780 2003-08-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3781
3782         * socket-io.c: fixed compilation for systems that define AF_INET6
3783         and don't define SOL_IP/SOL_IPV6.
3784
3785 2003-08-21  Zoltan Varga  <vargaz@freemail.hu>
3786
3787         * object.c (mono_object_isinst): Fix casts to TransparentProxy in
3788         the interpreter. Patch by Bernie Solomon (bernard@ugsolutions.com).
3789
3790         * rawbuffer.c rawbuffer.h: Make this module thread safe.
3791
3792         * domain.c: Make this module thread safe.
3793
3794         * domain.c (mono_init): Call new initialization function.
3795
3796         * icall.c (ves_icall_System_Array_SetValueImpl): Check types for
3797         reference types too. Fixes #38812.
3798
3799         * image.c (mono_image_init): Fixed warnings.
3800
3801         * class.c (mono_class_from_typeref): Handle assembly load failure
3802         correctly.
3803
3804         * appdomain.c (add_assemblies_to_domain): Handle the case when
3805         the references of an assembly are not yet loaded.
3806
3807         * metadata.c image.c assembly.c: Moved initialization of global
3808         variables to a separate function called at startup since lazy 
3809         initialization of these variables is not thread safe.
3810         
3811         * image.c assembly.c: Made this module thread safe by adding locks in 
3812         the appropriate places.
3813
3814         * domain.c (mono_init): Call the new initialization functions of the
3815         three modules.
3816
3817 2003-08-20  Lluis Sanchez Gual  <lluis@ximian.com>
3818
3819         * marshal.c: mono_delegate_begin_invoke(): If the target is a proxy,
3820           make a direct call. It is proxy's work to make the call asynchronous.
3821           mono_delegate_end_invoke(): If the targe is a proxy, just collect
3822           the return values.
3823         * object.cs: mono_method_call_message_new(): read AsyncResult and
3824           state object from parameters list, if this info is requested.
3825         * object.h: Added fields to store remote call output values in
3826           MonoAsyncResult. Added AsyncResult field in MonoMethodMessage.
3827
3828 Wed Aug 20 12:57:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
3829
3830         * object.h: add needed fields to MonoThread.
3831         * threads.c, threads.h: allow registering a function to cleanup data
3832         allocated per thread by the JIT.
3833
3834 Tue Aug 19 18:22:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
3835
3836         * loader.h: portability fix by Bernie Solomon
3837         * <bernard@ugsolutions.com>.
3838
3839 2003-08-16  Zoltan Varga  <vargaz@freemail.hu>
3840
3841         * reflection.h reflection.c (mono_param_get_objects): Changed this to 
3842         return a MonoArray. This simplifies the code and also ensures that
3843         the cache allways contains an object reference as a value.
3844
3845         * icall.c (ves_icall_get_parameter_info): Simplified using the new
3846         function.
3847
3848 2003-08-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3849
3850         * socket-io.c: patch by Bernie Solomon <bernard@ugsolutions.com> that
3851         fixes a problem with byte ordering when getting the address family for
3852         a socket.
3853
3854 2003-08-15  Zoltan Varga  <vargaz@freemail.hu>
3855
3856         * .cvsignore: Added monosn.
3857
3858         * reflection.h reflection.c loader.c: Added support for parameter
3859         marshalling to dynamically created types. Fixes #47295.
3860
3861 Fri Aug 15 11:42:46 CEST 2003 Paolo Molaro <lupus@ximian.com>
3862
3863         * rand.c: remove useless warnings.
3864
3865 Wed Aug 13 15:49:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
3866
3867         * class.c: implemented ldtoken for methods and fieldrefs.
3868
3869 2003-08-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3870
3871         * threadpool.c: when mono_async_invoke was called, no one took care of
3872         monitoring the queue. So if the method invoked took some time and we
3873         got new async invoke requests after 500 ms (the thread created waited
3874         that long in WaitForSingleObject), the new async invoke was not called
3875         until the previous one finished.
3876
3877         This is fixed now. Thanks to Totte for helping with it.
3878
3879 2003-08-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3880
3881         * threadpool.c: set threadpool_thread to TRUE. Patch by totte.
3882
3883 2003-08-11  Martin Baulig  <martin@ximian.com>
3884
3885         * mono-debug-debugger.c (mono_debugger_lookup_type): New function.
3886
3887 2003-08-06  Martin Baulig  <martin@ximian.com>
3888
3889         * mono-debug-debugger.c: Added support for static fields,
3890         properties and methods.
3891
3892 2003-08-06  Martin Baulig  <martin@ximian.com>
3893
3894         * mono-debug-debugger.c: Don't store the MonoString's vtable to
3895         make this work for applications with multiple application domains.
3896
3897 2003-08-04  Martin Baulig  <martin@ximian.com>
3898
3899         * mono-debug-debugger.c: Completely reworked the type support; the
3900         most important thing is that we're now just using one single
3901         `MonoType' instance per type.
3902
3903 Sat Aug  2 13:05:27 BST 2003 Malte Hildingson <malte@amy.udd.htu.se>
3904
3905         * mono-endian.h, mono-endian.c, icall.c: Added icall
3906         ves_icall_System_Double_AssertEndianity to assert double word endianity
3907         on ARM (FPA). The icall uses a macro defined in mono-endian.h.
3908
3909 Fri Aug 1 16:51:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
3910
3911         * class.c, class.h, reflection.c, metadata.c, icall.c: more generics
3912         support, icalls and fixes.
3913
3914 2003-07-31  Miguel de Icaza  <miguel@ximian.com>
3915
3916         * unicode.c (ves_icall_System_Char_IsPunctuation): The set of
3917         classes that are a punctuation character in .NET is not the same a
3918         g_unichar_ispunct.
3919
3920 Tue Jul 29 18:07:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
3921
3922         * socket-io.c: ipv6 portability fixes from Felix Ortga (guile@lared.es).
3923
3924 2003-07-29  Miguel de Icaza  <miguel@ximian.com>
3925
3926         * icall.c: Add new MemCopy internalcall.
3927         (ves_icall_System_Reflection_Assembly_GetManifestResourceInternal):
3928         Simplified code; It is not necessary to handle all the cases here,
3929         as the C# code takes care of it.  Only handle the case of the name
3930         resource embedded into the assembly.
3931
3932         Changed signature to return the data pointer and the size of the
3933         data. 
3934
3935 2003-07-26  Miguel de Icaza  <miguel@ximian.com>
3936
3937         * reflection.c (mono_image_get_method_info): Allow for 0x40 to be
3938         encoded.        (Partition II.22.1.7: PInvokeAttribute:SupportsLastErr).
3939
3940 2003-07-29  Lluis Sanchez Gual  <lluis@ximian.com>
3941
3942         * socket-io.c: ignore EINTR error in select.
3943
3944 Tue Jul 29 15:25:01 CEST 2003 Paolo Molaro <lupus@ximian.com>
3945
3946         * class.h, class.c: removed unused subclasses field in MonoClass.
3947
3948 2003-07-29  Lluis Sanchez Gual  <lluis@ximian.com>
3949
3950         * icall.c: improve fix of get_base_definition(). If the parent class
3951           doesn't have the mehod, look at the parent of the parent.
3952         * object.c: mono_message_init(): use the attribute PARAM_ATTRIBUTE_OUT
3953           to check if a parameter is an in or out parameter
3954           (PARAM_ATTRIBUTE_IN is not set by default).
3955           mono_method_return_message_restore(): Use mono_class_value_size to
3956           get the size of a value type. mono_type_stack_size (parameterType)
3957           does not return the correct value if parameterType is byRef.
3958           mono_load_remote_field(), mono_load_remote_field_new(),
3959           mono_store_remote_field(), mono_store_remote_field_new():
3960           raise exception if the remote call returns an exception.
3961
3962 2003-07-28  Martin Baulig  <martin@ximian.com>
3963
3964         * mono-debug-debugger.c (mono_debugger_runtime_invoke): New
3965         method.  This is a wrapper around mono_runtime_invoke() which
3966         boxes the instance object if neccessary.
3967
3968 Fri Jul 25 19:14:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
3969
3970         * class.c, class.h, image.c, image.h, loader.c, metadata.c,
3971         metadata.h, row-indexes.h, verify.c: first cut of generics support.
3972
3973 Thu Jul 24 11:34:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
3974
3975         * icall.c: disable mcs bug workaround.
3976
3977 2003-07-21  Miguel de Icaza  <miguel@ximian.com>
3978
3979         * object.c (mono_runtime_class_init): Take the metadata_section
3980         mutex before obtaining the domain mutex.
3981
3982         * appdomain.h: Added definition of metadata_section mutex here. 
3983
3984         * object.c: define metadata_mutex here.
3985
3986 2003-07-24  Ravi Pratap  <ravi@ximian.com>
3987
3988         * icall.c: Remove the FIXED_MCS_45127 workarounds - this has been
3989         fixed.
3990
3991 2003-07-24  Lluis Sanchez Gual  <lluis@ximian.com>
3992
3993         * reflection.c: Fix bug #46669
3994
3995 2003-07-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
3996
3997         * exception.c:
3998         * exception.h:
3999         * icall.c:
4000         * object.h: fill in the type name for TypeLoadException.
4001
4002 2003-07-23  Ravi Pratap  <ravi@ximian.com>
4003
4004         * class.c: Fixes from Paolo in response to bug #45415 (Subclass
4005         relationship between TypeBuilders while compiling corlib) and bug
4006         45993 (Array types returned from the runtime while compiling
4007         corlib were from the loaded corlib).
4008
4009 2003-07-22  Martin Baulig  <martin@ximian.com>
4010
4011         * mono-debug-debugger.c: Reworked the type support a bit more;
4012         distinguish between types and classes.
4013
4014 Tue Jul 22 15:48:50 CEST 2003 Paolo Molaro <lupus@ximian.com>
4015
4016         * icall.c: add IsArrayImpl icall.
4017
4018 2003-07-22  Zoltan Varga  <vargaz@freemail.hu>
4019
4020         * class.c (mono_class_layout_fields): Fix gc aware auto layout by
4021         initializing real_size only once. Also fix bug #46602.
4022
4023 2003-07-21  Jerome Laban <jlaban@wanadoo.fr>
4024
4025         * object.c: Renamed mono_metadata_section to metadata_section.
4026
4027 2003-07-21  Lluis Sanchez Gual  <lluis@ximian.com>
4028
4029         * icall.c: in MS.NET ves_icall_Type_GetInterfaces returns an
4030           empty array if the type is an array. Fixed.
4031           ves_icall_MonoMethod_get_base_definition: if the base method
4032           is abstract, get the MethodInfo from the list of methods of
4033           the class.
4034         * reflection.c: ParameterInfo.PositionImpl should be zero-based
4035           and it was 1-based. Fixed in mono_param_get_objects.
4036
4037 2003-07-20  Martin Baulig  <martin@ximian.com>
4038
4039         * mono-debug.h: Set version number to 31.
4040         (mono_debug_init): Added `MonoDomain *' argument.
4041
4042         * mono-debug-debugger.c: Reworked the type support; explicitly
4043         tell the debugger about builtin types; pass the `klass' address to
4044         the debugger.
4045
4046 2003-07-20 Jackson Harper <jackson@latitudegeo.com>
4047
4048         * image.c: Allow new metadata tables to be loaded without a
4049         warning. Also update the warning message to give the new constant value.
4050                 
4051 Fri Jul 18 13:12:21 CEST 2003 Paolo Molaro <lupus@ximian.com>
4052
4053         * class.c, class.h, debug-helpers.c, icall.c, image.c, marshal.c,
4054         metadata.c, metadata.h, mono-debug-debugger.c, object.c, reflection.c: 
4055         array type representation changes.
4056
4057 Fri Jul 18 11:26:58 CEST 2003 Paolo Molaro <lupus@ximian.com>
4058
4059         * icall.c, appdomain.h, appdomain.c: support full runtime shutdown
4060         on Environment.Exit () call.
4061
4062 Thu Jul 17 17:21:57 CEST 2003 Paolo Molaro <lupus@ximian.com>
4063
4064         * icall.c, reflection.h, reflection.c, verify.c: cleanups,
4065         requires a matching corlib.
4066
4067 2003-07-17  Lluis Sanchez Gual  <lluis@ximian.com>
4068
4069         * Changelog: My editor decided to add a CR to each line. Sorry about that.
4070           Committed again without the CRs.
4071         
4072 2003-07-17  Lluis Sanchez Gual  <lluis@ximian.com>
4073
4074         * socket-io.c: Get system_assembly using mono_image_loaded(), instead
4075           getting it from the "this" socket instance. Did not work
4076           if the socket is a subclass of Socket.
4077           Also fixed bug #35371.
4078
4079 Thu Jul 17 13:39:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
4080
4081         * metadata.c: fixed size for TypedByRef.
4082         * loader.c: when searching for a method, consider the vararg amrker.
4083         * unicode.c, decimal.c: constify some arrays.
4084
4085 2003-07-15  Dick Porter  <dick@ximian.com>
4086
4087         * socket-io.c: Fixed compilation for gcc < 3.2.
4088
4089         Fixed compilation for machines that don't have AF_INET6 (thanks to
4090         Bernie Solomon <bernard@ugsolutions.com> for that part.)
4091
4092         Fixed compile warnings.
4093         
4094         Fixed formatting and line endings.
4095
4096 2003-07-14  Jerome Laban <jlaban@wanadoo.fr>
4097
4098         * socket-io.h:
4099         * socket-io.c: Added IPv6 support.
4100
4101 2003-07-13  Zoltan Varga  <vargaz@freemail.hu>
4102
4103         * class.c (mono_class_is_assignable_from): New function to implement
4104         the is_assignable_from logic. Used by mono_object_isinst, 
4105         Type::IsAssignableFrom () and the interpreter.
4106
4107         * class.c (mono_class_is_subclass_of): Make all classes a subclass of
4108         Object, even interfaces.
4109         
4110         * object.c (mono_object_isinst): Implement in terms of 
4111         is_assignable_from.
4112
4113         * icall.c (ves_icall_type_is_assignable_from): New icall.
4114
4115 2003-07-11  Zoltan Varga  <vargaz@freemail.hu>
4116
4117         * domain.c (foreach_domain): fix compiler warning.
4118
4119 2003-07-11  Dietmar Maurer  <dietmar@ximian.com>
4120
4121         * image.c (load_metadata_ptrs): use g_strndup because strndup is
4122         not available on all plattforms
4123
4124 2003-07-10  Zoltan Varga  <vargaz@freemail.hu>
4125
4126         * image.h image.c: Store the metadata version string in MonoImage.
4127         * icall.c: New icall to retrieve the image version.
4128         * reflection.c (create_dynamic_image): Fill in the image version field
4129         * reflection.c (build_compressed_metadata): Use the image version
4130         from the image structure.
4131
4132 2003-07-08  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4133
4134         * appdomain.c: modified comment.
4135         * gc.c: finalizer_thread can call finalizers even when finished == TRUE.
4136         That will be its last iteration when mono_gc_cleanup is called from
4137         mono_runtime_cleanup and before the domain is unloaded.
4138
4139         Fixes bug #45962.
4140
4141 2003-07-04  Dietmar Maurer  <dietmar@ximian.com>
4142
4143         * marshal.c (mono_marshal_get_native_wrapper): fixes for [out]
4144         attributes.
4145
4146 Thu Jul 3 17:22:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
4147
4148         * object.c, file-io.c, metadata.c, mono-endian.h, reflection.c,
4149         rawbuffer.c: more 64 bit and picky (or old) compiler fixes from
4150         Bernie Solomon <bernard@ugsolutions.com>.
4151
4152 Thu Jul 3 17:17:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
4153
4154         * object.c, object.h: provide mono_object_new_fast() for faster
4155         allocation in some special cases.
4156
4157 Wed Jul 2 13:21:26 CEST 2003 Paolo Molaro <lupus@ximian.com>
4158
4159         * object.h, reflection.h, verify.c: fixes for some 64bit issues,
4160         mostly from a patch by Laramie Leavitt <lar@leavitt.us>.
4161
4162 Tue Jul 1 21:24:14 CEST 2003 Paolo Molaro <lupus@ximian.com>
4163
4164         * threadpool.c: fix leaks.
4165
4166 2003-07-01  Dick Porter  <dick@ximian.com>
4167
4168         * threadpool.c (mono_async_invoke): Use mono_g_hash_table_remove when
4169         using MonoGHashTables.  Fixes threadpool bug posted to list.
4170
4171 Tue Jul 1 11:45:40 CEST 2003 Paolo Molaro <lupus@ximian.com>
4172
4173         * image.h, image.c: added support to load an assembly from a byte array.
4174         * Makefile.am, assembly.c, make-bundle.pl, sample-bundle: added 
4175         assembly bundle support.
4176
4177 2003-06-27  Dietmar Maurer  <dietmar@ximian.com>
4178
4179         * threadpool.c (mono_thread_pool_add): keep a reference to the
4180         AsyncResult to prevent GC
4181
4182 Thu Jun 26 12:13:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
4183
4184         * class.c: leak fix.
4185
4186 2003-06-25  Dick Porter  <dick@ximian.com>
4187
4188         * threadpool.c (mono_thread_pool_add): Don't set up a finaliser
4189         for the async object, the WaitHandle object will close the handle.
4190         Fixes bug 45321.
4191
4192 Wed Jun 25 18:12:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
4193
4194         * class.c: in mono_array_class_get (), lookup from the hash with the
4195         same type we insert: this works around a bug in
4196         mono_metadata_type_hash() with SZARRAY and fixes a leak reported by
4197         lluis. The real fix will have to wait for after the release.
4198
4199 Wed Jun 25 13:14:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
4200
4201         * icall.c: fix memory leak when getting type members.
4202
4203 Mon Jun 23 16:12:48 CEST 2003 Paolo Molaro <lupus@ximian.com>
4204
4205         * reflection.c: added more pubtoken special cases.
4206
4207 Mon Jun 23 15:29:06 CEST 2003 Paolo Molaro <lupus@ximian.com>
4208
4209         * class.c: handle field offset correctly when class size
4210         is set (bug# 45182, partially from a patch by jlaban@wanadoo.Fr (Jerome Laban)).
4211
4212 2003-06-20  Martin Baulig  <martin@ximian.com>
4213
4214         * mono-debug-debugger.h (MonoDebuggerSymbolFile): Added `MonoImage
4215         *image' field.
4216
4217 2003-06-20  Martin Baulig  <martin@ximian.com>
4218
4219         * image.h, mono-debug-debugger.h: Fixed compiler warnings.
4220
4221 2003-06-20  Martin Baulig  <martin@ximian.com>
4222
4223         * mono-debug.h (MONO_DEBUG_VAR_ADDRESS_MODE_STACK): Removed.  We
4224         just distinguish between variables in registers and variables at
4225         an offset relative to a register.
4226
4227 2003-06-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4228
4229         * icall.c: #ifdef out latest changes until mcs is fixed.
4230
4231 Thu Jun 19 11:03:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
4232
4233         * icall.c: return members in metadata order.
4234
4235 Wed Jun 18 15:26:58 CEST 2003 Paolo Molaro <lupus@ximian.com>
4236
4237         * icall.c: avoid infinite loop in GetTimeZoneData.
4238
4239 Wed Jun 18 12:47:43 CEST 2003 Paolo Molaro <lupus@ximian.com>
4240
4241         * icall.c: added Marshal.Prelink/All icalls.
4242
4243 Wed Jun 18 12:17:48 CEST 2003 Paolo Molaro <lupus@ximian.com>
4244
4245         * object.c, object.h: fix warnings and do some overflow checking
4246         when creating arrays.
4247
4248 2003-06-17  Dick Porter  <dick@ximian.com>
4249
4250         * file-io.h:
4251         * file-io.c: File attributes need to be tweaked slightly when
4252         passed from the managed to the w32 world.
4253
4254 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
4255         * profiler.h profiler-private.h profiler.c: Rework last patch
4256         based on suggestion by Paolo.
4257         
4258 2003-06-17  Zoltan Varga  <vargaz@freemail.hu>
4259
4260         * profiler.h profiler-private.h profiler.c: Added infrastructure for 
4261         instruction level coverage data collection.
4262         * profiler.h profiler.c (: Added new callback function which can be
4263         used by the profiler to limit which functions should have coverage
4264         instrumentation.
4265         * profiler.c (mono_profiler_load): Call g_module_build_path to
4266         generate the file name of the profiler library.
4267
4268 Mon Jun 16 18:11:13 CEST 2003 Paolo Molaro <lupus@ximian.com>
4269
4270         * profiler.c, profiler.h, profiler-private.h: added basic block 
4271         coverage profiling API.
4272
4273 2003-06-15  Zoltan Varga  <vargaz@freemail.hu>
4274
4275         * reflection.c (mono_reflection_create_runtime_class): Add support
4276         for events in dynamically generated code.
4277
4278         * gc.c: Start GCHandle indexes from 1, since 0 means the handle is
4279         not allocated.
4280
4281 Sat Jun 14 19:01:32 CEST 2003 Paolo Molaro <lupus@ximian.com>
4282
4283         * icall.c: when getting timezone info, return reasonable values if we
4284         can't get the actual data.
4285
4286 2003-06-14  Dick Porter  <dick@ximian.com>
4287
4288         * threads.c (start_wrapper): Remove the reference to the thread
4289         object in the TLS data, so the thread object can be finalized.
4290         This won't be reached if the thread threw an uncaught exception,
4291         so those thread handles will stay referenced :-( (This is due to
4292         missing support for scanning thread-specific data in the Boehm GC
4293         - the io-layer keeps a GC-visible hash of pointers to TLS data.)
4294
4295 Sat Jun 14 13:16:17 CEST 2003 Paolo Molaro <lupus@ximian.com>
4296
4297         * reflection.c: ensure streams and tables are first allocated with
4298         ALLOC_ATOMIC (GC_realloc uses plain GC_malloc otherwise).
4299
4300 Sat Jun 14 13:13:20 CEST 2003 Paolo Molaro <lupus@ximian.com>
4301
4302         * icall.c: fixed GetElementType for byrefs (bug# 44792).
4303
4304 2003-06-13  Zoltan Varga  <vargaz@freemail.hu>
4305
4306         * reflection.c (mono_reflection_create_runtime_class): Add support for
4307         properties to dynamically created classes.
4308         * reflection.c: Fix a few places where non-MonoObjects were inserted
4309         into the tokens hashtable.
4310
4311 Fri Jun 13 19:10:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
4312
4313         * object.c: some support to handle out of memory exceptions.
4314
4315 2003-06-12  Dietmar Maurer  <dietmar@ximian.com>
4316
4317         * marshal.c (mono_marshal_get_native_wrapper): support reference
4318         return types
4319
4320 Wed Jun 11 18:32:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
4321
4322         * object.h, object.c: more portability stuff from Bernie Solomon.
4323         Unexport mono_object_allocate(). Added mono_object_unbox ().
4324         Set exitcode when an unhandled exception is thrown.
4325
4326 2003-06-11  Dietmar Maurer  <dietmar@ximian.com>
4327
4328         * marshal.c (mono_marshal_get_native_wrapper): use custom
4329         marshaler for return types.
4330
4331 2003-06-10  Dick Porter  <dick@ximian.com>
4332
4333         * socket-io.c: Don't assume that one of struct ip_mreqn or struct
4334         ip_mreq is available
4335
4336 Tue Jun 10 17:35:03 CEST 2003 Paolo Molaro <lupus@ximian.com>
4337
4338         * debug-mono-symfile.c, marshal.c, metadata.c, monitor.c,
4339         mono-debug-debugger.c, mono-debug.c, process.c: portability fixes
4340         by Bernie Solomon <bernard@ugsolutions.com>.
4341
4342 2003-06-10  Zoltan Varga  <vargaz@freemail.hu>
4343
4344         * gc.c (mono_gc_init): Avoid error message on shutdown when
4345         GC_DONT_GC=1 is used.
4346
4347         * icall.c (ves_icall_System_Reflection_Module_GetGuidInternal): 
4348         New icall to return the GUID of a module.
4349
4350 Mon Jun 9 19:33:51 CEST 2003 Paolo Molaro <lupus@ximian.com>
4351
4352         * class.c: ensure instance size always includes the parent's size
4353         even whem class size is set explicitly (fixes bug#44294).
4354
4355 Thu Jun 5 19:51:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
4356
4357         * profiler.h, profiler.c: made the simple profiler thread-safe,
4358         get more accurate timing info. Allow the loading of an
4359         externally-developed profiler module.
4360
4361 2003-06-05  Dietmar Maurer  <dietmar@ximian.com>
4362
4363         * marshal.c (mono_marshal_get_native_wrapper): improved
4364         class/byref arguments.
4365         (mono_marshal_get_native_wrapper): better string marshaling support.
4366
4367 Wed Jun 4 18:01:22 CEST 2003 Paolo Molaro <lupus@ximian.com>
4368
4369         * class.c: ensure .pack and .size are handled correctly and
4370         simplified layout of static fields.
4371
4372 2003-06-04  Dietmar Maurer  <dietmar@ximian.com>
4373
4374         * appdomain.c
4375         (ves_icall_System_AppDomainSetup_InitAppDomainSetup): fix for bug 42934
4376
4377         * loader.c (mono_lookup_pinvoke_call): look for modules in the
4378         current directory (fix bug 44008)
4379
4380 2003-06-03  Dietmar Maurer  <dietmar@ximian.com>
4381
4382         * marshal.c (mono_marshal_get_native_wrapper): started support for
4383         custom marshalers.
4384         (mono_delegate_to_ftnptr): consider marshalling specifications
4385
4386 Tue Jun 3 11:17:02 CEST 2003 Paolo Molaro <lupus@ximian.com>
4387
4388         * reflection.c, reflection.h: emit custom marshal info.
4389
4390 2003-06-02  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4391
4392         * object.c: free the GError.
4393         * icall.c: added CloseEvent_internal.
4394         * threads.[ch]:
4395         (ves_icall_System_Threading_Events_CloseEvent_internal): new internal
4396         call.
4397
4398 2003-06-01  Zoltan Varga  <vargaz@freemail.hu>
4399
4400         * loader.c (mono_method_get_signature): Add support for dynamic
4401         assemblies.
4402
4403 Sat May 31 15:22:07 CEST 2003 Paolo Molaro <lupus@ximian.com>
4404
4405         * reflection.c: fixed bug #43905.
4406
4407 Fri May 30 12:56:29 CEST 2003 Paolo Molaro <lupus@ximian.com>
4408
4409         * class.c, domain.c, icall.c, metadata.h, object.h: support for
4410         handling TypedReference and ArgIterator.
4411         * loader.c, loader.h: added function to get signature at call site.
4412
4413 Thu May 29 11:34:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
4414
4415         * metadata.c, metadata.h, private.h, tokentype.h, loader.c: make more 
4416         data readonly. Buglets and warning fixes. Some MethodSpec support.
4417
4418 Tue May 27 16:34:39 CEST 2003 Paolo Molaro <lupus@ximian.com>
4419
4420         * class.h, class.c, object.c: remove relative numbering support.
4421
4422 2003-05-26  Miguel de Icaza  <miguel@ximian.com>
4423
4424         * marshal.c (mono_marshal_get_native_wrapper): For now, do not
4425         free the string, until we get a chance to fix Gtk#
4426
4427 2003-05-27  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4428
4429         * marshal.c: revert last patch.
4430
4431 Mon May 26 20:21:52 CEST 2003 Paolo Molaro <lupus@ximian.com>
4432
4433         * icall.c: updates for new mono_class_vtable() not calling
4434         the type constructor anymore.
4435
4436 Mon May 26 12:10:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
4437
4438         * object.h, object.c: separate vtable creation from type
4439         initialization. Make running the .cctor thread safe.
4440
4441 2003-05-26  Dietmar Maurer  <dietmar@ximian.com>
4442
4443         * marshal.c (mono_marshal_get_native_wrapper): free string return values.
4444
4445 2003-05-21  Dietmar Maurer  <dietmar@ximian.com>
4446
4447         * loader.c (mono_get_method): consider calling convention
4448
4449 2003-05-21  Zoltan Varga  <vargaz@freemail.hu>
4450
4451         * icall.c (ves_icall_System_Reflection_Module_GetGlobalType): New icall
4452         to return the invisible global type for a module.
4453
4454         * reflection.c (mono_image_build_metadata): Emit global fields too.
4455
4456 2003-05-20  Peter Williams  <peterw@ximian.com>
4457
4458         * loader.c (mono_lookup_internal_call): Add a few newlines.
4459
4460 2003-05-20  Zoltan Varga  <vargaz@freemail.hu>
4461
4462         * reflection.c (mono_reflection_lookup_dynamic_token): Intern dynamic
4463         literal strings.
4464
4465         * appdomain.c (set_domain_search_path): Recalculate search path when
4466         AppDomainSetup.PrivateBinPath changes.
4467
4468         * object.c (mono_class_compute_gc_descriptor): It turns out some
4469         parts of the class libs (like System.Thread) holds pointers to
4470         GC_MALLOC()-d memory in IntPtrs, which is wrong. The workaround is
4471         to treat native int a pointer type here.
4472         
4473 Tue May 20 17:18:16 CEST 2003 Paolo Molaro <lupus@ximian.com>
4474
4475         * appdomain.h, domain.c: add hashtable for jump target resolution.
4476
4477 2003-05-19  Zoltan Varga  <vargaz@freemail.hu>
4478
4479         * reflection.h reflection.c icall.c: Added new icalls 
4480         GetManifestResourceInfoInternal, GetModulesInternal and support
4481         infrastructure.
4482
4483 2003-05-16  Dick Porter  <dick@ximian.com>
4484
4485         * icall.c:
4486         * file-io.h:
4487         * file-io.c: Implement System.IO.MonoIO::GetTempPath
4488
4489 2003-05-14  Lluis Sanchez Gual  <lluis@ideary.com>
4490
4491         * object.c: mono_store_remote_field: little fix to previous patch.
4492
4493 Wed May 14 18:10:42 CEST 2003 Paolo Molaro <lupus@ximian.com>
4494
4495         * class.c: add constructors to array classes.
4496         * icall.c: special case array construction for InternalInvoke (),
4497
4498 2003-05-14  Zoltan Varga  <vargaz@freemail.hu>
4499
4500         * class.h class.c reflection.c object.c: Added support for field
4501         defaults in dynamically generated classes.
4502
4503 Wed May 14 13:35:27 CEST 2003 Paolo Molaro <lupus@ximian.com>
4504
4505         * reflection.c: properly encode charset for ddlimport.
4506
4507 Wed May 14 11:14:54 CEST 2003 Paolo Molaro <lupus@ximian.com>
4508
4509         * threads.c: allow compiling without GC.
4510
4511 Tue May 13 16:41:49 CEST 2003 Paolo Molaro <lupus@ximian.com>
4512
4513         * appdomain.h, object.c, object.h, threads.c, threads.h: added
4514         handling of thread static data.
4515
4516 Tue May 13 16:36:08 CEST 2003 Paolo Molaro <lupus@ximian.com>
4517
4518         * reflection.h, reflection.c: added mono_custom_attrs_free ().
4519
4520 2003-05-13  Dietmar Maurer  <dietmar@ximian.com>
4521
4522         * class.c (mono_array_class_get): always set the serializable flags
4523         (mono_array_class_get): always set the SEALED attribute for array types
4524
4525 2003-05-12  Dietmar Maurer  <dietmar@ximian.com>
4526
4527         * loader.c (mono_lookup_pinvoke_call): consider Ansi/Unicode
4528         attributes (fix for bug 42021).
4529
4530 2003-05-12  Dick Porter  <dick@ximian.com>
4531
4532         * gc.c: Don't run finalizers when the finalizer thread is
4533         finishing up, because the default domain has already been
4534         destroyed.
4535
4536 2003-05-11  Miguel de Icaza  <miguel@ximian.com>
4537
4538         * string-icalls.c (ves_icall_System_String_ctor_chara_int_int): if
4539         value is null, we should throw an exception.   This is slightly
4540         different than the other conventions used for the constructor.
4541
4542 2003-05-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4543
4544         * socket-io.c: fixed windows build.
4545
4546 2003-05-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4547
4548         * socket-io.c: patch by Jerome Laban that fixes bug #42393.
4549
4550 2003-05-10  Zoltan Varga  <vargaz@freemail.hu>
4551
4552         * object.c (mono_string_new_wrapper): Compatibility fix for MS
4553         compilers.
4554
4555 2003-05-09  Zoltan Varga  <vargaz@freemail.hu>
4556
4557         * class.c (mono_class_layout_fields): Add experimental GC aware
4558         auto layout facility. Requires class library changes to work correctly.
4559
4560         (mono_class_setup_vtable): Avoid overriding explicit interface
4561         method implementations. Fixes iface3.exe test.
4562
4563         * object.c (mono_class_compute_gc_descriptor): Type I can't hold an
4564         object reference.
4565         (mono_array_new_specific): Add MONO_ARCH_SAVE_REGS.
4566         (mono_string_new_wrapper): Add MONO_ARCH_SAVE_REGS.
4567
4568         * metadata.h: Add new type classification macro which determines
4569         whenever the type holds an object reference.
4570
4571 2003-05-08  Dietmar Maurer  <dietmar@ximian.com>
4572
4573         * marshal.c (mono_marshal_get_native_wrapper): cleanups
4574
4575 2003-05-07  Zoltan Varga  <vargaz@freemail.hu>
4576
4577         * gc.c (finalizer_thread): Work around a GC bug.
4578
4579 2003-05-07  Dietmar Maurer  <dietmar@ximian.com>
4580
4581         * marshal.c (emit_struct_conv): allow unions
4582
4583         * class.c (class_compute_field_layout): added patches from Jerome Laban <jlaban@wanadoo.fr>
4584
4585 2003-05-06  Dietmar Maurer  <dietmar@ximian.com>
4586
4587         * marshal.c (mono_marshal_get_native_wrapper): free strings after pinvoke
4588
4589 2003-05-06  Martin Baulig  <martin@ximian.com>
4590
4591         * mono-debug-debugger.h: #include <mono/io-layer/io-layer.h>.
4592
4593 2003-05-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4594
4595         * socket-io.c:
4596         (Select_internal): allow NULLs, don't create arrays if not needed.
4597         Coupled with Socket.cs changes.
4598
4599         * threadpool.c:
4600         (mono_thread_pool_add): use GC_MALLOC to allocate the ASyncCall and
4601         register a finalizer for it that will close the semaphore handle. This
4602         fixes the leak and make Lupus' test run with > 4080 loops.
4603
4604 2003-05-05  Dietmar Maurer  <dietmar@ximian.com>
4605
4606         * marshal.c (mono_marshal_get_struct_to_ptr): added fixes from
4607         Jerome Laban (bug #42287)
4608
4609 2003-05-02  Martin Baulig  <martin@ximian.com>
4610
4611         * debug-mono-symfile.h
4612         (MonoSymbolFile): Moved declaration into mono-debug.h.
4613         (MonoDebugMethodJitInfo): Likewise.
4614         (mono_debug_open_mono_symbol_file): Take the MonoDebugHandle as
4615         argument.
4616         (_mono_debug_address_from_il_offset): Take a
4617         MonoDebugMethodJitInfo instead of a MonoDebugMethodInfo.
4618
4619         * mono-debug.h
4620         (MonoDebugDomainData): New struct.
4621         (mono_debug_get_domain_data): New function.
4622         (mono_debug_add_method): Take an additional `MonoDomain *'
4623         argument.
4624         (mono_debug_source_location_from_address): Likewise.
4625         (mono_debug_il_offset_from_address): Likewise.
4626         (mono_debug_address_from_il_offset): Likewise.
4627
4628 Thu May 1 19:40:37 CEST 2003 Paolo Molaro <lupus@ximian.com>
4629
4630         * reflection.c: one more check for null type in custom attrs.
4631
4632 2003-05-01  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4633
4634         * reflection.c: avoid warning (comparison is always false due to limited
4635         range of data type).
4636
4637 2003-05-01  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4638
4639         * icall.c: throw an exception in Type.GetField if the argument 'name'
4640         is NULL.
4641
4642 Wed Apr 30 10:53:09 CEST 2003 Paolo Molaro <lupus@ximian.com>
4643
4644         * reflection.c: fixed handling of enums in named arguments to custom
4645         attributes (bug #42123).
4646
4647 Tue Apr 29 19:15:10 CEST 2003 Paolo Molaro <lupus@ximian.com>
4648
4649         * reflection.c: use the right array element type and handle
4650         a null for a Type argument, too.
4651
4652 Tue Apr 29 15:46:00 CEST 2003 Paolo Molaro <lupus@ximian.com>
4653
4654         * reflection.c: handle arrays as arguments to custom attributes.
4655
4656 Tue Apr 29 11:43:01 CEST 2003 Paolo Molaro <lupus@ximian.com>
4657
4658         * reflection.c: handle a string value in a custom attr
4659         ctor that takes an object.
4660
4661 2003-04-29  Dietmar Maurer  <dietmar@ximian.com>
4662
4663         * marshal.c (mono_mb_emit_restore_result): support MONO_TYPE_PTR
4664         (fix bug #42063)
4665
4666 2003-04-28  Zoltan Varga  <vargaz@freemail.hu>
4667
4668         * icall.c (ves_icall_Type_GetNestedType): Fixed warnings.
4669
4670 2003-04-27  Martin Baulig  <martin@ximian.com>
4671
4672         * mono-debug-debugger.h (MonoDebuggerEvent): Renamed
4673         MONO_DEBUGGER_EVENT_BREAKPOINT_TRAMPOLINE to
4674         MONO_DEBUGGER_EVENT_BREAKPOINT.
4675         (mono_breakpoint_trampoline_code): Removed.
4676         (mono_debugger_event_handler): The last argument is now a
4677         `guint32'.
4678         (mono_debugger_insert_breakpoint_full): Removed the
4679         `use_trampoline' argument.
4680         (mono_debugger_method_has_breakpoint): Likewise.
4681         (mono_debugger_trampoline_breakpoint_callback): Renamed to
4682         mono_debugger_breakpoint_callback(); take the method and
4683         breakpoint number as arguments.
4684
4685 Sat Apr 26 19:25:31 CEST 2003 Paolo Molaro <lupus@ximian.com>
4686
4687         * metadata.c: fix off by one when loading parameters attributes.
4688
4689 2003-04-24  Martin Baulig  <martin@ximian.com>
4690
4691         * mono-debug-debugger.c (mono_debugger_io_layer): Put this back.
4692
4693 2003-04-24  Martin Baulig  <martin@ximian.com>
4694
4695         * mono-debug-debugger.c: Moved all code which interacts with the
4696         Mono Debugger here.
4697
4698         * debug-mono-symfile.c: This code now just deals with the symbol
4699         file itself, the debugger code is now in mono-debug-debugger.c.
4700
4701 2003-04-23  Martin Baulig  <martin@ximian.com>
4702
4703         * mono-debug.c (mono_debug_source_location_from_il_offset):
4704         New method; like mono_debug_source_location_from_address(), but
4705         takes an IL offset instead of a machine address.
4706
4707 2003-04-23  Martin Baulig  <martin@ximian.com>
4708
4709         * debug-mono-symfile.h (MonoDebugLineNumberEntry): Removed the
4710         `line' field; this is now computed by the debugger.
4711
4712 2003-04-23  Martin Baulig  <martin@ximian.com>
4713
4714         * mono-debug.[ch]: New files.  This is the new debugging interface.
4715
4716         * mono-debug-debugger.[ch]: New files.  Moved all code which
4717         interacts with the Mono Debugger here.
4718
4719 2003-04-22  Dietmar Maurer  <dietmar@ximian.com>
4720
4721         * domain.c (mono_init): initialize mono_defaults.monitor_class
4722
4723 2003-04-21  Miguel de Icaza  <miguel@ximian.com>
4724
4725         * reflection.c (method_encode_code): Add a spicy exception to help
4726         future compiler authors.
4727
4728 2003-04-21  Martin Baulig  <martin@ximian.com>
4729
4730         * icall.c
4731         (ves_icall_System_Reflection_Assembly_GetReferencedAssemblies):
4732         Make this work with relative pathnames; g_filename_to_uri() needs
4733         an absolute filename.
4734
4735 2003-04-18  Zoltan Varga  <vargaz@freemail.hu>
4736
4737         * icall.c: Track name changes in Object and ValueType.
4738
4739 2003-04-18  Dietmar Maurer  <dietmar@ximian.com>
4740
4741         * metadata.c (mono_type_stack_size): size should be a multiple of
4742         sizeof (gpointer)
4743
4744 2003-04-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4745
4746         * gc.c:
4747         (internal_domain_finalize): moved into mono_domain_finalize. No need
4748         to create another thread because the finalizers will be run in the
4749         finalizer thread.
4750         
4751         (ves_icall_System_GC_WaitForPendingFinalizers): implemented.
4752         (finalizer_notify): if shutting down, wait 2 seconds for the finalizers
4753         to be run (MS does this too).
4754
4755 2003-04-17  Zoltan Varga  <vargaz@freemail.hu>
4756
4757         * object.c (mono_class_compute_gc_descriptor): Update comment.
4758
4759         * loader.h marshal.h marshal.c: Added synchronized method wrappers.
4760
4761         * image.h: Add synchronized wrapper cache.
4762
4763         * image.c (do_mono_image_open): Initialize cache.
4764
4765         * reflection.c (create_dynamic_mono_image): Initialize cache.
4766
4767 2003-04-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4768
4769         * icall.c: patch by Jerome Laban <jlaban@wanadoo.fr> that fixes
4770         ves_icall_System_Buffer_ByteLengthInternal.
4771
4772 Tue Apr 15 13:56:55 CEST 2003 Paolo Molaro <lupus@ximian.com>
4773
4774         * reflection.c: setup klass->nested_in earlier. Allow
4775         a dash in the assembly name.
4776
4777 2003-04-15  Dietmar Maurer  <dietmar@ximian.com>
4778
4779         * metadata.c (mono_type_to_unmanaged): dont access
4780         type->data.klass for MONO_TYPE_OBJECT
4781         (mono_type_to_unmanaged): consider System.Delegate class
4782
4783 Tue Apr 15 11:16:05 CEST 2003 Paolo Molaro <lupus@ximian.com>
4784
4785         * class.c: just setup supertypes in the proper place instead of
4786         initializing the full element class for arrays.
4787
4788 Tue Apr 15 11:03:25 CEST 2003 Paolo Molaro <lupus@ximian.com>
4789
4790         * class.c: ensure the element class of arrays is initialized.
4791         Setup the supertype info for array classes, too.
4792
4793 2003-04-14  Miguel de Icaza  <miguel@ximian.com>
4794
4795         * icall.c (ves_icall_Type_GetNestedType): Add new internal call.
4796
4797 2003-04-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4798
4799         * Makefile.am: re-added -m option when running cygpath. This way,
4800         MONO_ASSEMBLIES and MONO_CFG_DIR will contain '/' as directory
4801         separator.
4802         * mono-config.c: same codepath for locating mono config file for WIN32
4803         and the rest.
4804         * assembly.c: if mono_assembly_setrootdir is called, don't override
4805         the value set.
4806
4807 2003-04-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4808
4809         * Makefile.am: patch by Urs Muff <umuff@quark.com> that fixes
4810         MONO_ASSEMBLIES variable.
4811
4812 Fri Apr 11 12:44:15 CEST 2003 Paolo Molaro <lupus@ximian.com>
4813
4814         * icall.c: added Assembly::GetNamespaces() icall.
4815
4816 2003-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4817
4818         * reflection.c: fix from Jaak <jaak@zd.com.pl>.
4819
4820 2003-04-10  Lluis Sanchez Gual  <lluis@ideary.com>
4821
4822         * appdomain.c,appdomain.h,icall.c: Added internal method that returns the process guid
4823         * object.c: fixed bug in the construction of vtable for proxies
4824
4825 2003-04-10  Zoltan Varga  <vargaz@freemail.hu>
4826
4827         * object.c (mono_array_new): Mark mono_array_new as an icall.
4828
4829 2003-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4830
4831         * class.c: fixed test for public method when overriding interfaces.
4832         Closes bug #40970.
4833
4834 Wed Apr 9 15:19:41 CEST 2003 Paolo Molaro <lupus@ximian.com>
4835
4836         * appdomain.h, domain.c: added mono_domain_foreach() to
4837         be able to access the currently loaded appdomains.
4838         * object.c: make string interning work across sppdomains.
4839         Mark some functions for use as icalls.
4840
4841 2003-04-09  Zoltan Varga  <vargaz@freemail.hu>
4842
4843         * class.c reflection.c: Fix memory leaks reported by ccmalloc.
4844
4845         * reflection.h reflection.c: Allocate long living data using 
4846         GC_MALLOC_ATOMIC so the collector does not need to scan it.
4847
4848         * reflection.c: Double the allocation size in streams instead of
4849         increasing it, to prevent unneccesary copying on large assemblies.
4850         
4851         * reflection.c (mono_reflection_create_runtime_class): Avoid vtable
4852         creation if the assembly does not have the Run flag set.
4853
4854 Tue Apr 8 11:19:53 CEST 2003 Paolo Molaro <lupus@ximian.com>
4855
4856         * class.h: avoid the C++ keywords in header files (Jerome Laban
4857         spotted and fixed this).
4858
4859 2003-04-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
4860
4861         * object.c:
4862         (mono_unhandled_exception): fill in the arguments for the
4863         UnhandledException event. Only trigger that event for the default
4864         domain (as MS does).
4865
4866 2003-04-04  Zoltan Varga  <vargaz@freemail.hu>
4867
4868         * object.c: Improve typed allocation stuff based on suggestions from
4869         Paolo. Also turn it on if the GC library supports it.
4870
4871 2003-04-03  Zoltan Varga  <vargaz@freemail.hu>
4872
4873         * object.c object.h class.h: Added experimental typed allocation
4874         facility using the interfaces in gc_gcj.h.
4875
4876         * os/gc_wrapper.h: Added new include files.
4877         
4878 2003-04-03  Martin Baulig  <martin@ximian.com>
4879
4880         All the following changes are conditional to `WITH_INCLUDED_LIBGC'
4881         which is not yet enabled by default.
4882
4883         * gc.c (mono_gc_init): Set the gc_thread_vtable to our thread
4884         functions.
4885         (mono_gc_lock, mono_gc_unlock): New static functions.
4886
4887         * threads.c (mono_gc_stop_world, mono_gc_start_world): New public
4888         functions; stop/start the world for the garbage collector.  This
4889         is using the windows API; we need to complete the SuspendThread()/
4890         ResumeThread() implementation in the io-layer to make this work on Unix.
4891         (mono_gc_push_all_stacks): New public function; tells the garbage
4892         collector about the stack pointers from all managed threads.
4893
4894 2003-04-03  Martin Baulig  <martin@ximian.com>
4895
4896         * object.h (MonoThread): Added `gpointer stack_ptr'.
4897
4898         * threads.c (start_wrapper): Save the stack pointer in `stack_ptr'.
4899
4900 2003-04-03  Martin Baulig  <martin@ximian.com>
4901
4902         * Makefile.am: It's called `cygpath -w', not `cygpath -m'.
4903
4904 2003-04-03  Zoltan Varga  <vargaz@freemail.hu>
4905
4906         * reflection.c (typebuilder_setup_fields): Initialize field.first and
4907         field.last.
4908
4909 2003-04-02  Miguel de Icaza  <miguel@ximian.com>
4910
4911         * loader.c (mono_lookup_internal_call): Report the corlib that is
4912         out of sync.
4913
4914 2003-03-05  Aleksey Demakov <avd@openlinksw.com>
4915
4916         * icall.c (ves_icall_type_GetTypeCode): fixed check for
4917         System.DBNull (it's class not valuetype).
4918
4919 Wed Apr 2 18:37:35 CEST 2003 Paolo Molaro <lupus@ximian.com>
4920
4921         * reflection.c: set table_idx in MonoReflectionArrayMethod object even 
4922         if the array method was already assigned a token (fixes bug#40646).
4923
4924 2003-04-02  Zoltan Varga  <vargaz@freemail.hu>
4925
4926         * reflection.c (mono_reflection_get_type): Attempt type resolve even
4927         if no assembly is given.
4928
4929 2003-04-01  Miguel de Icaza  <miguel@ximian.com>
4930
4931         * metadata.h: Added the new tables.
4932
4933         * row-indexes.h: Added definitions for new tables.
4934
4935         * metadata.c: Add schemas for new tables, and add support for
4936         computing the sizes of them.
4937
4938         * class.c: Update for handling the new type cases.
4939
4940 2003-04-01  Dietmar Maurer  <dietmar@ximian.com>
4941
4942         * metadata.h (MONO_TYPE_IS_VOID): new macro
4943
4944 2003-03-31  Martin Baulig  <martin@ximian.com>
4945
4946         * threads.h (MonoThreadCallbacks): Added `thread_created'.
4947
4948         * threads.c (mono_thread_new_init): Call `thread_created' in the
4949         mono_thread_callbacks.
4950
4951 2003-03-31  Lluis Sanchez Gual <lluis@ideary.com>
4952
4953         * loader.h: added marshalbyrefobject_class to mono_defaults
4954         * domain.c: added initialization of mono_defaults.marshalbyrefobject_class 
4955         * icall.c: ves_icall_InternalExecute: fixed bug in field setter and in the
4956           generation of output parameters.
4957           ves_icall_Remoting_RealProxy_GetTransparentProxy: added support for interfaces.
4958         * marshal.c: mono_remoting_wrapper(): avoided call through proxy when the type is
4959           contextbound and the target object belongs to the context of the caller.
4960         * object.h: added context and unwrapped_server variables in MonoRealProxy.
4961         * object.c: Implemented support for interfaces and abstract classes
4962           in mono_class_proxy_vtable. Fixed several methods to avoid unneeded calls through
4963           proxy. Fixed problem when dealing with output parameters in mono_runtime_invoke_array.
4964
4965 2003-03-30  Zoltan Varga  <vargaz@freemail.hu>
4966
4967         * class.h class.c (mono_class_is_subclass_of): New function.
4968         
4969         * icall.c (ves_icall_System_Array_FastCopy): Added optimized copy
4970         routines for most common case (calls from ArrayList::ToArray).
4971
4972         * icall.c (ves_icall_System_Environment_Exit): Call profiler shutdown 
4973         routine so programs which call Environment::Exit() can be profiled.
4974
4975         * icall.c (ves_icall_System_Reflection_FieldInfo_internal_from_handle): 
4976         Added MONO_ARCH_SAVE_REGS.
4977
4978         * icall.c (ves_icall_type_is_subtype_of): Use new function.
4979
4980 2003-03-29  Miguel de Icaza  <miguel@ximian.com>
4981
4982         * blob.h: Add a couple of new MonoType types definitions.
4983
4984         * tabledefs.h: Add a couple of new call convs.
4985
4986 2003-03-27  Zoltan Varga  <vargaz@freemail.h>
4987
4988         * reflection.h (MonoReflectionDynamicAssembly): track changes in
4989         the layout of the class.
4990
4991         * reflection.c (alloc_table): double the size on overflow to avoid
4992         unnecessary copying.
4993
4994         * reflection.h reflection.c: If AssemblyBuilderAccess is Run, then
4995         avoid filling out metadata tables and blobs. Also set mb->ilgen to
4996         null so it can be garbage collected.
4997         
4998 2003-03-27  Zoltan Varga  <vargaz@freemail.hu>
4999
5000         * reflection.c (mono_reflection_get_type): Return the resolved type
5001         only if it is in the assembly we searched.
5002
5003         * reflection.c (ensure_runtime_vtable): Initialize method slots.
5004
5005         * class.c (mono_class_setup_vtable): Set the slot of the overriding
5006         method.
5007
5008 2003-03-26  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5009
5010         * appdomain.c:
5011         (set_domain_search_path): allow 'file://blah'. It's an invalid URI,
5012         the right one is 'file:///blah', but MS allows it.
5013         * assembly.c:
5014         (mono_assembly_open): allow 'file://blah'
5015
5016         Fixes bug #40306. Thanks to Mitko Iliev (imitko@openlinksw.co.uk).
5017
5018 2003-03-26  Aleksey Demakov <avd@openlinksw.com>
5019
5020         * socket-io.c: fixes bug #40310.
5021
5022 2003-03-25  Zoltan Varga  <vargaz@freemail.hu>
5023
5024         * reflection.c (mono_reflection_parse_type): handle deeply nested
5025         types correctly.
5026
5027         * reflection.c (mono_image_create_token): Use unique token values
5028         since they will be put into a hash table.
5029
5030         * class.c (mono_class_setup_vtable): If a method occurs in more than
5031         one place in the vtable, and it gets overriden, then change the
5032         other occurances too.
5033
5034         * marshal.c (mono_marshal_get_managed_wrapper): Added support for
5035         object as return type.
5036
5037 2003-03-22  Pedro Martínez Juliá  <yoros@wanadoo.es>
5038
5039         * icall.c: Deleted "ToString" implementation for double and float
5040         because they are full implemented in managed code.
5041
5042 Wed Mar 19 18:05:57 CET 2003 Paolo Molaro <lupus@ximian.com>
5043
5044         * reflection.c, reflection.h: implemented and exported functions
5045         to retrieve info about custom attributes.
5046
5047 2003-03-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5048
5049         * appdomain.c: moved Uri handling to assembly.c
5050         * assembly.c: use g_filename_from_uri (). This makes assembly.LoadFrom
5051         work when using a file Uri in *nix and windows.
5052
5053         * icall.c: fixed Assembly.CodeBase to return a valid Uri. The same for
5054         GetReferencedAssemblies.
5055
5056 2003-03-18  Dick Porter  <dick@ximian.com>
5057
5058         * icall.c: Rename a couple of internal calls
5059
5060         * threads.c: Set the thread state to Stopped when a thread exits.
5061         Fixes bug 39377.
5062
5063 2003-03-17  Zoltan Varga  <vargaz@freemail.hu>
5064
5065         * icall.c (ves_icall_System_Reflection_FieldInfo_internal_from_handle):
5066         New icall.
5067
5068         * object.c (mono_class_vtable): fix warning.
5069
5070 2003-03-17  Zoltan Varga  <vargaz@freemail.hu>  
5071
5072         * icall.c (ves_icall_type_is_subtype_of): Avoid vtable creation.
5073
5074         * reflection.c (mono_blob_entry_hash): Avoid reading uninitialized
5075         memory.
5076         (method_encode_clauses): Create exception info structures in the right
5077         order.
5078         (mono_reflection_setup_internal_class): Initialize supertypes field.
5079
5080         * class.c object.c: Handle interfaces which implement other interfaces 
5081         correctly.
5082
5083         * class.h class.c: Move the supertypes array initialization code into 
5084         a separate function so it can be used for dynamic types too. Also call
5085         it earlier, in mono_class_init(), since it can be used before the
5086         type is initialized.
5087
5088 2003-03-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5089
5090         * Makefile.am:
5091         * assembly.c:
5092         * icall.c: make MONO_ASSEMBLIES and MONO_CFG_DIR work on windows.
5093
5094         * appdomain.c:
5095         * appdomain.h:
5096         * marshal.c:
5097         * object.c: remove warnings.
5098
5099 2003-03-13  Martin Baulig  <martin@ximian.com>
5100
5101         * debug-mono-symfile.h (MonoSymbolFileLexicalBlockEntry): New type.
5102         (MonoDebugLexicalBlockEntry): New types.
5103
5104         * debug-mono-symfile.c
5105         (_mono_debug_address_from_il_offset): Moved here from ../jit/debug.c.
5106
5107 2003-03-13  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5108
5109         * process.c: ret can be any non-zero value accroding to MS doc.
5110
5111 2003-03-07  Miguel de Icaza  <miguel@ximian.com>
5112
5113         * class.c (mono_marshal_load_type_info): Fix buglet:  Noticed when
5114         fixing a warning for a miss-used prototype, would have cause
5115         random memory corruption.
5116
5117 2003-03-07  Martin Baulig  <martin@ximian.com>
5118
5119         * marshal.c (mono_marshal_free_array): That "TESTFREE %p" was
5120         getting really annoying ....
5121
5122 2003-03-07  Zoltan Varga  <vargaz@freemail.hu>
5123
5124         * reflection.c (fixup_method): added support for array methods.
5125
5126 Tue Mar 4 18:03:27 CET 2003 Paolo Molaro <lupus@ximian.com>
5127
5128         * socket-io.c:  handle case when AF_INET6 and AF_IPX are not defined
5129         (pointed out by Michael Adams).
5130
5131 2003-03-04  Dick Porter  <dick@ximian.com>
5132
5133         * icall.c: Temporarily reverted the Double and Single ToString()
5134         change, because it broke nunit.
5135
5136 Tue Mar 4 12:40:58 CET 2003 Paolo Molaro <lupus@ximian.com>
5137
5138         * object.h, threads.h: make include files compatible with C++
5139         (patch by Jerome Laban <jlaban@wanadoo.fr>).
5140
5141 2003-03-04  Pedro Martínez Juliá  <yoros@wanadoo.es>
5142
5143         * icall.c: Erased ToString helper functions for Double and Single.
5144         Now, that implementations ar all in managed code (Double and Single
5145         Formatters).
5146
5147 2003-03-03  Lluis Sanchez Gual  <lluis@ideary.com>
5148
5149         * appdomain.c: Added method for initializing the default context of
5150         a domain. Added internal call for getting the default context.
5151         * appdomain.h: Added context variable in MonoDomain struct.
5152         * domain.c: mono_domain_set also sets the default context of the domain
5153         * icall.c: Mapped internal method InternalGetDefaultContext.
5154         * object.c: mono_object_get_virtual_method returns always a remoting
5155         wrapper if the object is a transparent proxy.
5156         mono_runtime_invoke_array: when creating an object by calling the
5157         constructor, if the created object is a proxy, then the constructor should
5158         be called using the a remoting wrapper.
5159
5160 2003-03-03  Dick Porter  <dick@ximian.com>
5161
5162         * socket-io.c (create_sockaddr_from_object): Rename sockaddr_un
5163         variable so it compiles on solaris.  Problem spotted by
5164         Christopher Taylor <ct@cs.clemson.edu>
5165
5166 2003-03-01  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5167
5168         * appdomain.c:
5169         (get_info_from_assembly_name): don't leak value.
5170
5171         * icall.c:
5172         (ves_icall_System_Reflection_Assembly_GetFilesInternal): initialize
5173         result.
5174
5175 Sat Mar 1 15:32:56 CET 2003 Paolo Molaro <lupus@ximian.com>
5176
5177         * assembly.c: export mono_image_load_references ().
5178         * class.c: handle function pointers. mono_class_from_name() now
5179         supports nested type names directly.
5180
5181 2003-02-28  Zoltan Varga  <vargaz@freemail.hu>
5182
5183         * reflection.h reflection.c: Encode already created dynamic methods 
5184         and fields correctly as a DEF instead of a REF.
5185
5186         * reflection.c: Get rid of the force_ref argument to 
5187         mono_image_typedef_or_ref since it was wrong in the first place.
5188
5189         * string-icalls.c: add error checking to string constructors according
5190         to the MSDN docs.
5191
5192         * reflection.c: Emit types in the order their TypeBuilders were 
5193         created. Previously, a new table index was assigned to each type before
5194         the tables were emitted. This was wrong because the signature blob
5195         might already refer to a type by its original table index.
5196
5197 2003-02-27  Zoltan Varga  <vargaz@freemail.hu>
5198
5199         * metadata.c (mono_metadata_nesting_typedef): fix bug in previous
5200         change.
5201         
5202 2003-02-27  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5203
5204         * Makefile.am: make assemblies dir have \ instead of / on windows.
5205
5206 2003-02-27  Zoltan Varga  <vargaz@freemail.hu>  
5207
5208         * metadata.c metadata.h (mono_metadata_nesting_typedef): changed to
5209         iterate over the NESTEDCLASS table using a linear search since the
5210         table is not guaranteed to be sorted by the secondary key.
5211
5212         * class.c (mono_class_create_from_typedef): fixed up call to
5213         mono_metadata_nesting_typedef.
5214         
5215 2003-02-27  Dietmar Maurer  <dietmar@ximian.com>
5216
5217         * marshal.c (mono_string_to_byvalstr): clear the memory as
5218         suggested by Jerome Laban <jlaban@wanadoo.fr>
5219
5220 2003-02-26  Dick Porter  <dick@ximian.com>
5221
5222         * process.c: Cope with padding in .rsrc blocks
5223
5224 2003-02-26  Dietmar Maurer  <dietmar@ximian.com>
5225
5226         * metadata.h: reverted the filter_len change, it breaks reflection
5227         
5228 2003-02-26  Dietmar Maurer  <dietmar@ximian.com>
5229
5230         * metadata.h: added a new field to store the filter_len
5231         
5232
5233 Tue Feb 25 10:56:16 CET 2003 Paolo Molaro <lupus@ximian.com>
5234
5235         * reflection.c: handle custom attributes for types and members
5236         created with Reflection.Emit (bug#38422).
5237
5238 2003-02-22  Zoltan Varga  <vargaz@freemail.hu>
5239
5240         * reflection.c: define RTSpecialName automatically for constructors for
5241         compatibility with MS.NET.
5242
5243         * reflection.c (mono_reflection_create_runtime_class): initialize
5244         nested_in field of dynamically created classes.
5245
5246 2003-02-22  Martin Baulig  <martin@ximian.com>
5247
5248         * debug-mono-symfile.h: Incremented version number.
5249
5250 2003-02-21  Zoltan Varga  <vargaz@freemail.hu>
5251
5252         * object.h icall.c process.c: fix warnings.
5253
5254 2003-02-21  Zoltan Varga  <vargaz@freemail.hu>
5255
5256         * appdomain.h appdomain.c:
5257         (mono_domain_try_type_resolve): split the 
5258         name_or_tb argument into a name and a tb argument.
5259         (mono_domain_has_type_resolve): new function to check whenever the
5260         application has registered a TypeResolve event handler.
5261         
5262         * icall.c reflection.h reflection.c: move the type resolve logic into
5263         mono_reflection_get_type () so it will be invoked when 
5264         Assembly::GetType () is called.
5265
5266         * reflection.c:
5267         (mono_reflection_get_type): renamed to get_type_internal.
5268         (mono_reflection_get_type): fixed type name generation so it works 
5269         for nested types too.
5270         (mono_reflection_get_type): call has_type_resolve () to avoid the 
5271         costly type name generation if there is no resolve event handler.
5272
5273 Fri Feb 21 11:36:57 CET 2003 Paolo Molaro <lupus@ximian.com>
5274
5275         * class.c, image.c: load exported types from file references.
5276
5277 2003-02-19  Lluis Sanchez Gual  <lluis@ideary.com>
5278
5279         * appdomain.h: Added in MonoDomain a couple of MonoMethod* variables
5280           used to cache the managed methods used to create proxies and make 
5281           remote invocation of methods.
5282         * class.h: Added in MonoVTable a flag to indicate that a class needs 
5283           to be remotely created.
5284         * object.c: Modified the method mono_class_vtable(). It now initializes 
5285           the remote flag of the vtable. Modified mono_object_new_specific(), 
5286           so now it checks the remote flag.
5287         * icall.c: Added a couple of internal methods, one for enabling instance 
5288           creation interception for a type, and one for creating objects bypassing
5289           the remote check.
5290
5291 2003-02-18  Martin Baulig  <martin@ximian.com>
5292
5293         * debug-mono-symfile.c (ves_icall_MonoDebugger_GetMethodToken):
5294         New interncall to get a method's metadata token.
5295
5296         * icall.c ("System.Reflection.Assembly::MonoDebugger_GetMethodToken"):
5297         New interncall for the debugger.
5298
5299 2003-02-18  Dietmar Maurer  <dietmar@ximian.com>
5300
5301         * class.c (mono_class_setup_vtable): allocate supertype array
5302
5303 2003-02-18  Martin Baulig  <martin@ximian.com>
5304
5305         * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Added `has_this'.
5306
5307 2003-02-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5308
5309         * reflection.c:
5310         (assembly_name_to_aname): jump over unknown properties (i've found
5311         something like: 'type, assembly, version=xxx, custom=null, public...',
5312         so now will ignore custom=null and still get the rest of the values).
5313
5314 2003-02-17  Dick Porter  <dick@ximian.com>
5315
5316         * threads.c: Have Thread.Start() wait for a semaphore to signal
5317         that the thread has set up all its local data.  This fixes bug
5318         34323, where Abort() raced the new thread's TLS data.
5319
5320         Also removes the handle_store() call from start_wrapper, because
5321         threads are now always created suspended and there is no longer a
5322         race between the parent and child threads to store the info.
5323
5324 Mon Feb 17 13:13:31 CET 2003 Paolo Molaro <lupus@ximian.com>
5325
5326         * image.c: explain the #- heap issue in a message, hopefully
5327         avoiding FAQs on mono-list.
5328
5329 2003-02-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5330
5331         * icall.c:
5332         (GetEntryAssembly): if the domain has not invoked
5333         AppDomain.ExecuteAssembly yet, return the assembly of the default
5334         AppDomain.
5335
5336 2003-02-16  Zoltan Varga  <vargaz@freemail.hu>
5337
5338         * class.c (mono_ldtoken): make it work in dynamic assemblies.
5339
5340 Sun Feb 16 13:10:06 CET 2003 Paolo Molaro <lupus@ximian.com>
5341
5342         * metadata.c, reflection.c: simple speedup to type hash
5343         and equals code.
5344
5345 Sat Feb 15 15:15:03 CET 2003 Paolo Molaro <lupus@ximian.com>
5346
5347         * image.c, image.h, class.c, assembly.c: move module loading
5348         to MonoImage. When loading metadata, consider alignemnet from
5349         the start of metadata, not from the metadata address in memory.
5350
5351 2003-02-13  Zoltan Varga  <vargaz@freemail.hu>
5352
5353         * reflection.c (mono_reflection_get_custom_attrs): Added support for 
5354         AssemblyBuilder objects. Factored out custom attribute creation into
5355         a separate function.
5356         (create_custom_attr): new function to create custom attributes.
5357
5358 2003-02-12  Miguel de Icaza  <miguel@ximian.com>
5359
5360         * Makefile.am: Got tired of typing the full pathname to pedump.
5361         Until there is another option, am installing this.
5362
5363 2003-02-12  Dietmar Maurer  <dietmar@ximian.com>
5364
5365         * class.c (class_compute_field_layout): always set field->parent 
5366         (mono_ldtoken): use mono_defaults.fieldhandle_class;
5367
5368 2003-02-11  Dick Porter  <dick@ximian.com>
5369
5370         * threads-types.h:
5371         * monitor.c: Rewrote Monitor, making lock much faster and
5372         Pulse/Wait work as specified.  Also uses much fewer handles, and only
5373         creates them as needed.
5374
5375         * exception.c: Added SynchronizationLockException
5376
5377         * threads.c: Deleted old Monitor implementation.  The new one is
5378         in a new file.
5379
5380 Mon Feb 10 17:54:10 CET 2003 Paolo Molaro <lupus@ximian.com>
5381
5382         * class.c: handled TypedReference type code. Set the correct size for
5383         class data. Setup interface_offsets for interface classes, too.
5384
5385 2003-02-09  Martin Baulig  <martin@ximian.com>
5386
5387         * debug-mono-symfile.h: Reflect latest symbol writer changes.
5388
5389 Sun Feb 9 18:37:01 CET 2003 Paolo Molaro <lupus@ximian.com>
5390
5391         * loader.c: implemented MEMBERREF_PARENT_TYPEDEF.
5392         * metadata.c, reflection.c: missing MONO_TYPE_TYPEDBYREF handling.
5393         * object.c: fixed mono_object_get_virtual_method () for interfaces.
5394         * verify.c: check for code that runs after the end of the method.
5395
5396 2003-02-08  Pedro Martínez Juliá  <yoros@wanadoo.es>
5397
5398         * icall.c: Added "System.Math::Floor", "System.Math::Round" and
5399         "System.Math::Round2".
5400         * sysmath.h: Added Floor, Round and Round2 definitions.
5401         * sysmath.c: Modified certain functions that were not 100% compliant
5402         with MS.NET (math precision) and added the implementation of Floor,
5403         Round and Round2.
5404
5405 2003-02-07  Martin Baulig  <martin@ximian.com>
5406
5407         * debug-mono-symfile.c (mono_debug_symfile_add_method): Ignore interncalls.
5408
5409 2003-02-07  Martin Baulig  <martin@ximian.com>
5410
5411         * debug-mono-symfile.c: Reflected latest symwriter changes.
5412         (mono_debug_create_mono_symbol_file): Removed.
5413         (mono_debug_open_mono_symbol_file): Take an argument which
5414         specifies whether to create a dynamic symbol file.
5415
5416 2003-02-07  Dietmar Maurer  <dietmar@ximian.com>
5417
5418         * class.c (mono_class_from_mono_type): added MONO_TYPE_TYPEDBYREF
5419
5420 2003-02-05  Martin Baulig  <martin@ximian.com>
5421
5422         * reflection.c (mono_image_build_metadata): Make this public,
5423         protect it against being called multiple times, don't create
5424         resources and don't build the compressed metadata here.
5425         (mono_image_create_pefile): Do this here.
5426
5427         * icall.c
5428         ("System.Reflection.Emit.AssemblyBuilder::build_metadata"): Added.
5429
5430 2003-02-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5431
5432         * socket-io.c: fixed bug #36322.
5433
5434 2003-02-06  Piers Haken <piersh@friskit.com>
5435
5436         * appdomain.[ch]:
5437         * class.h:
5438         * debug-mono-symfile.c:
5439         * icall.c:
5440         * loader.c:
5441         * mono-config.c:
5442         * monosn.c:
5443         * reflection.c:
5444         * socket-io.c: warning cleanups
5445
5446 2003-02-06  Dietmar Maurer  <dietmar@ximian.com>
5447
5448         * marshal.c (mono_marshal_get_remoting_invoke_with_check): new
5449         function. works like remoting invoke, but does a check for the Proxy first.
5450
5451 2003-02-05  Miguel de Icaza  <miguel@ximian.com>
5452
5453         * appdomain.c (ves_icall_System_AppDomain_InternalUnload): Make it compiler.
5454
5455 2003-02-05  Dietmar Maurer  <dietmar@ximian.com>
5456
5457         * marshal.c (mono_marshal_get_native_wrapper): only allocate an
5458         array of pointers.
5459         (mono_marshal_get_ldfld_wrapper): only generate necessary ldfld wrappers.
5460         (mono_marshal_get_stfld_wrapper): only generate necessary stfld wrappers.
5461
5462         * object.c (mono_store_remote_field_new): used by the new jit
5463         instead of mono_store_remote_field
5464         (mono_load_remote_field_new): used by the new jit
5465         instead of mono_load_remote_field
5466
5467 2003-02-05  Patrik Torstensson
5468
5469         * appdomain.c: changed unload to take the domain id instead
5470         of domain
5471         
5472         * icall.c: changed icall for AppDomain.Unload to AppDomain.InternalUnload
5473
5474
5475 2003-02-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5476
5477         * appdomain.c: don't look for assemblies in ApplicationBase if
5478         PrivateBinPathProbe is set.
5479
5480 2003-02-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5481
5482         * object.c: make the first argument in main_args contain the absolute
5483         path to the assembly. Fixes bug #37511.
5484
5485 2003-02-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5486
5487         * icall.c: get correct UTC offset for countries not using daylight
5488         time saving. Fixes bug #30030.
5489
5490 2003-02-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5491
5492         * socket-io.c: support AF_UNIX and use the same layout as MS (bytes 0
5493         and 1 are the family).
5494
5495 2003-02-04  Dietmar Maurer  <dietmar@ximian.com>
5496
5497         * icall.c (ves_icall_InternalExecute): removed wrong assertion
5498
5499         * marshal.c (mono_marshal_get_remoting_invoke): generate valid IL
5500
5501 2003-02-04  Zoltan Varga  <vargaz@freemail.hu>
5502
5503         * reflection.c: added support for SignatureHelper tokens, which is
5504         needed by the Calli opcode.
5505
5506         * reflection.h: track changes to SignatureHelper class.
5507
5508         * metadata.c (mono_metadata_parse_signature): handle dynamic tokens.
5509
5510 2003-02-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5511
5512         * appdomain.c: fixed loading assemblies from PrivateBinPath.
5513
5514 2003-02-03  Patrik Torstensson
5515         * appdomain.[c|h], domain.c : 
5516          - Added support for getting a domain via domain id
5517          - Support for setting and getting domain from System.AppDomain 
5518            (used in cross appdomain channel)
5519          - Added support for get/set for a MonoAppContext on a thread 
5520            (Context class in System.Runtime.Remoting.Contexts),
5521          - Removed hack in Get/SetData and ExecuteAssembly.
5522         
5523         * icall.c : renamed GetTransparantProxy to InternalGetTransparantProxy to allow
5524         the managed world to get control when a proxy is created.
5525
5526         * icall.c (ves_icall_InternalExecute) : bug fix, must return empty array
5527         
5528 2003-02-03  Miguel de Icaza  <miguel@ximian.com>
5529
5530         * icall.c
5531         (ves_icall_System_Reflection_Assembly_GetReferencedAssemblies):
5532         Populate the codebase field as well.
5533
5534 2003-02-02  Martin Baulig  <martin@ximian.com>
5535
5536         * debug-mono-symfile.c
5537         (MonoSymbolFileMethodAddress): Added `wrapper_address' field.
5538         (mono_debug_symfile_add_method): Allow interncalls.
5539
5540 2003-01-31  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5541
5542         * icall.c: throw parse exception if strtod fails or the string is empty.
5543
5544 Fri Jan 31 16:09:48 CET 2003 Paolo Molaro <lupus@ximian.com>
5545
5546         * marshal.c: handle object type separately from defined
5547         class types.
5548
5549 Fri Jan 31 16:01:20 CET 2003 Paolo Molaro <lupus@ximian.com>
5550
5551         * marshal.c: handle NATIVE_LPSTR for strings when it's
5552         explicitly specified.
5553
5554 Fri Jan 31 11:51:43 CET 2003 Paolo Molaro <lupus@ximian.com>
5555
5556         * reflection.c, reflection.h, icall.c: setup the reflection
5557         handle cache for ModuleBuilders and AssemblyBuilders.
5558
5559 2003-01-30  Dietmar Maurer  <dietmar@ximian.com>
5560
5561         * reflection.c (reflection_methodbuilder_to_mono_method): set
5562         pinvoke flag
5563
5564 2003-01-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5565
5566         * icall.c: implemented ves_icall_MonoMethod_get_base_definition.
5567
5568 2003-01-29  Dick Porter  <dick@ximian.com>
5569
5570         * threads.c: No need for the fake_thread kludge now that Thread
5571         doesn't run a class constructor
5572         
5573 2003-01-29  Dick Porter  <dick@ximian.com>
5574
5575         * threads.c: Use g_direct_hash instead of the rather bogus
5576         g_int_hash
5577
5578 2003-01-29  Dietmar Maurer  <dietmar@ximian.com>
5579
5580         * marshal.c (mono_marshal_get_native_wrapper): add check for null
5581         (fix pinvoke12.exe)
5582         (mono_marshal_get_struct_to_ptr): generate valid IL code
5583         (mono_marshal_get_ptr_to_struct): generate valid IL code
5584         (*): correctly set sig->pinvoke, we need to memdup the signature
5585         to do that
5586
5587 Tue Jan 28 22:57:57 CET 2003 Paolo Molaro <lupus@ximian.com>
5588
5589         * marshal.c, marshal.h: use larger integers in mono_mb_emit_add_to_local()
5590         to avoid overflows (bug spotted and fixed by Jerome Laban <jlaban@wanadoo.fr>).
5591
5592 Tue Jan 28 18:55:19 CET 2003 Paolo Molaro <lupus@ximian.com>
5593
5594         * profiler.c: provide more callers information.
5595
5596 2003-01-28  Dietmar Maurer  <dietmar@ximian.com>
5597
5598         * marshal.c (mono_marshal_get_managed_wrapper): generate valid IL code
5599
5600         * appdomain.h:added fix from Patrik: _MonoAppDomain is a MBR object
5601
5602         * marshal.c (mono_marshal_get_native_wrapper): generate valid IL code
5603
5604 2003-01-27  Zoltan Varga  <vargaz@freemail.hu>
5605
5606         * icall.c: (ves_icall_System_CurrentTimeZone_GetTimeZoneData): raise an
5607         exception instead of going into an infinite loop on dates which it 
5608         can't yet handle.
5609
5610         * string-icalls.c (ves_icall_System_String_get_Chars): raise 
5611         out-of-range exception if needed.
5612
5613         * class.c (mono_class_setup_vtable): allow a virtual method to provide
5614         an implementation for an interface method and to override an inherited
5615         method at the same time. 
5616         Imagine a scenario when a virtual method is used to override a
5617         virtual abstract method in a parent class, and this same method 
5618         provides an implementation for an method inherited from an interface. 
5619         In this case, the interface resolution code will set im->slot, which 
5620         means that the virtual method override pass will skip this method 
5621         which means a pointer to the abstract method inherited from the parent
5622         will remain in the vtable of this non-abstract class.
5623
5624         * class.c: (mono_class_setup_vtable): continue search for a real 
5625         method if only an abstract method is found.     
5626
5627 Mon Jan 27 17:12:19 CET 2003 Paolo Molaro <lupus@ximian.com>
5628
5629         * reflection.c: add size to encoding for ByValStr and ByValArray
5630         marshal blob (from "Jerome Laban" <jlaban@wanadoo.fr>).
5631
5632 2003-01-27  Zoltan Varga  <vargaz@freemail.hu>
5633
5634         * class.c (mono_class_setup_vtable): pass the override info as an
5635         argument.
5636
5637         * class.c (mono_class_setup_vtable): set the slot of overriding methods
5638         correctly.
5639         
5640         * reflection.c (ensure_runtime_vtable); add support for method 
5641         overrides.
5642         
5643 2003-01-27  Zoltan Varga  <vargaz@freemail.hu>
5644
5645         * reflection.c (resolution_scope_from_image): Hack to work to work with
5646         dynamic assemblies.
5647
5648         * reflection.c (mono_image_typedef_or_ref): renamed to ..._aux and 
5649         added a 'force_ref' argument to force this function to allways return 
5650         a TypeRef. This is needed by mono_image_get_memberref_token ().
5651         
5652 2003-01-27  Zoltan Varga  <vargaz@freemail.hu>
5653
5654         * reflection.c (mono_image_get_type_info): interfaces really don't have
5655         a parent.
5656
5657         * reflection.c (mono_image_basic_init): fill out missing fields of
5658         image structure.
5659
5660         * reflection.c (mono_image_basic_init): Invoke assembly load hooks for 
5661         dynamic assemblies. This is required so dynamic assemblies show up in
5662         AppDomain.GetAssemblies (), emit an AssembyLoadEvent, gets searched by
5663         Type::GetType() etc. This is consistent with MS behaviour.
5664
5665         * image.c image.h reflection.c: add newly created classes to the name 
5666         cache so mono_class_get () will find them.      
5667
5668 2003-01-27  Zoltan Varga  <vargaz@freemail.hu>
5669
5670         First part of changes to get IKVM.NET running under mono.
5671         
5672         * appdomain.h, appdomain.c: added new function 
5673         mono_domain_try_type_resolve() which will emit TypeResolve events. 
5674         This function will call AppDomain::DoTypeResolve to do the actual work.
5675
5676         * class.h, class.c, loader.c, object.c, reflection.h, reflection.c: 
5677         moved existing code dealing with dynamic tokens to a new function 
5678         called mono_reflection_lookup_dynamic_token (). This function will 
5679         raise TypeResolve events when appropriate. Since reflection.c is not 
5680         part of libmetadata, a new hook function called 
5681         mono_lookup_dynamic_token() is added to class.c which will call this.
5682
5683         * assembly.h assembly.c: make the invoke_load_hook function public,
5684         so it can be called for dynamic assemblies.
5685
5686         * icall.c (ves_icall_System_Runtime_CompilerServices_RuntimeHelpers_RunClassConstructor): skip interfaces since they do not have initializers.
5687
5688         * icall.c (ves_icall_type_from_name): emit a TypeResolve event if the 
5689         type isn't found.
5690
5691         * reflection.c reflection.h: change MonoDynamicAssembly.tokens to a 
5692         MonoGHashTable, since it contains pointers to objects which the GC 
5693         needs to track.
5694
5695         * assembly.c (search_loaded): remove unused variable.
5696         
5697 Mon Jan 27 12:18:45 CET 2003 Paolo Molaro <lupus@ximian.com>
5698
5699         * object.c: fixed issue exposed by gcc-generated IL programs
5700         that use RVA data for pointers.
5701
5702 2003-01-25  Martin Baulig  <martin@ximian.com>
5703
5704         * threads.c (start_wrapper): Moved the initialization of
5705         `start_func' above the mono_new_thread_init() call to which we
5706         pass it as argument.
5707
5708 2003-01-24  Martin Baulig  <martin@ximian.com>
5709
5710         * threads.h (MonoThreadCallbacks): Pass the thread ID instead of
5711         the MonoThread pointer.
5712
5713 2003-01-21  Miguel de Icaza  <miguel@ximian.com>
5714
5715         * icall.c: Rename `PowImpl' to Pow.
5716
5717 2003-01-23  Dick Porter  <dick@ximian.com>
5718
5719         * threads.c (start_wrapper): Create a Thread object if needed, so
5720         the Main() thread can do the class initialisation in a subthread
5721         that has been set up to allow managed code execution.
5722
5723         Pass the thread ID instead of the MonoThread pointer to the thread
5724         start and attach callbacks.  This change is required, because the
5725         jit thread start callback must be called _before_ the Thread
5726         object can be created.
5727         
5728         (mono_thread_init): Removed much object creation code that is no
5729         longer needed.  No managed code is called from here now.
5730
5731         * object.c (mono_runtime_exec_managed_code): Create a subthread
5732         for Main, and call back to the runtime to use it.
5733         Set the exit code when Main exits.
5734
5735         * gc.c: Make sure domain finalisation happens in a subthread.
5736         Re-enable threaded GC, fixing bug 31333 (again).
5737
5738         * environment.c: System.Environment internall calls (so far just
5739         ExitCode is here, the others are still in icall.c)
5740
5741         * appdomain.c (mono_runtime_cleanup): All threads running managed
5742         code should have finished before mono_runtime_cleanup() is
5743         reached, so no need to clean up threads.
5744
5745 2003-01-22  Martin Baulig  <martin@ximian.com>
5746
5747         * appdomain.h (MonoThreadStartCB): Added `MonoThread *thread' and
5748         `gpointer func' arguments.      
5749         (MonoThreadAttachCB): New typedef; like the old MonoThreadStartCB,
5750         but added `MonoThread *thread' argument.
5751         (mono_runtime_init): The last argument is now a MonoThreadAttachCB.
5752
5753         * threads.c (mono_new_thread_init): Added `gpointer func' argument
5754         and pass it to the mono_thread_start_cb callback.
5755         (mono_install_thread_callbacks): New public function to install a
5756         set of callbacks which are set by the debugger.
5757         (mono_thread_init): The last argument is now a MonoThreadAttachCB.
5758
5759 2003-01-22  Martin Baulig  <martin@ximian.com>
5760
5761         * Makefile.am: Install debug-mono-symfile.h.
5762
5763 2003-01-21  Aleksey Demakov <avd@openlinksw.com>
5764
5765         * marshal.c: fixed copy_from_managed and copy_to_unmanaged for 0 length.
5766
5767 2003-01-21  Dietmar Maurer  <dietmar@ximian.com>
5768
5769         * added the following fix from Jackson Harper <jackson@latitudegeo.com>
5770         * class.c (mono_ptr_class_get): correctly set access levels of pointers
5771         (mono_array_class_get): correctly set access levels of arrays
5772
5773 2003-01-20      Patrik Torstensson
5774         * image.h (MonoAssemblyName): changed major, minor, build, revision
5775         from signed to unsigned.
5776
5777 2003-01-20  sean kasun <skasun@azstarnet.com>
5778
5779         * reflection.c (load_cattr_value): Now this handles
5780         MONO_TYPE_SZARRAY.  Fixes bug #35629
5781
5782 2003-01-20  Miguel de Icaza  <miguel@ximian.com>
5783
5784         * marshal.c (emit_struct_conv): Handle MONO_TYPE_PTR as an
5785         integer value
5786
5787 2003-01-18  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5788
5789         * decimal.c: fixed bug #26056.
5790
5791 2003-01-17  Martin Baulig  <martin@ximian.com>
5792
5793         * gc.c: Raise an ExecutionEngineException instead of using g_error().
5794
5795 2003-01-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5796
5797         * exception.[ch]:
5798         (mono_get_exception_type_initialization): new function.
5799
5800         * object.c: throw a TypeInitializationException when an exception is
5801         thrown invoking the class constructor.
5802
5803 2003-01-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5804
5805         * reflection.c: fixed attribute reading.
5806
5807 2003-01-15  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5808
5809         * icall.c:
5810         (ves_icall_type_from_name): make it work as MS. Ie, if no assembly name
5811         provided, look for the type in the calling assembly and then in
5812         mscorlib; if the assembly name is provided, only try that one.
5813
5814 Tue Jan 14 14:52:52 CET 2003 Paolo Molaro <lupus@ximian.com>
5815
5816         * object.c: register the vtable before there is a chance it's
5817         queried again recursively.
5818
5819 2003-01-13  Duncan Mak  <duncan@ximian.com>
5820
5821         * Makefile.am (libmonoruntime_la_SOURCES): Change gc.h to
5822         gc-internal.h. 
5823         
5824 2003-01-12  Patrik Torstensson <totte@race-x-change.com>
5825
5826         * string-icall.[c|h], icall.c: Added support for CompareOrdinal mode
5827
5828 2003-01-11  Martin Baulig  <martin@ximian.com>
5829
5830         * debug-mono-symfile.h (MONO_SYMBOL_FILE_DYNAMIC_VERSION): Incremented
5831         this to 20 for the release.
5832
5833 2003-01-10  Dietmar Maurer  <dietmar@ximian.com>
5834
5835         * marshal.c (emit_struct_conv): added support for EXPLICIT_LAYOUT
5836
5837         * loader.c (mono_method_get_marshal_info): bug fix
5838
5839         * marshal.c (mono_marshal_get_ptr_to_struct): don't convert
5840         structures with explicit layout
5841
5842 Fri Jan 10 15:58:09 CET 2003 Paolo Molaro <lupus@ximian.com>
5843
5844         * profiler.c: made the output more readable (and sorted). 
5845         Added caller information for the allocation profiler.
5846
5847 2003-01-09  Sebastien Pouliot  <spouliot@videotron.ca>
5848
5849         * icall.c, rand.c, rand.h: Prepended RNG functions with Internal.
5850
5851 2003-01-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5852
5853         * icall.c: added ves_icall_System_Activator_CreateInstanceInternal. Used
5854         to get value types.
5855         
5856 Thu Jan 9 19:43:11 CET 2003 Paolo Molaro <lupus@ximian.com>
5857
5858         * object.c, profiler.h, profiler.c, profiler-private.h:
5859         Added object allocation profiler.
5860
5861 Thu Jan 9 16:17:00 CET 2003 Paolo Molaro <lupus@ximian.com>
5862
5863         * reflection.h, reflection.c: handle global methods.
5864         Compress blob entries.
5865
5866 Thu Jan 9 15:54:53 CET 2003 Paolo Molaro <lupus@ximian.com>
5867
5868         * marshal.c: fix compilation.
5869
5870 2003-01-09  Dietmar Maurer  <dietmar@ximian.com>
5871
5872         * loader.c (mono_method_get_marshal_info): impl.
5873
5874         * metadata.c (mono_metadata_field_info): use mono_metadata_get_marshal_info
5875
5876 2003-01-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5877
5878         * icall.c: applied fix from Zoltan Varga that fixes Type.IsPrimitive
5879         for reference types.
5880
5881 Wed Jan 8 20:11:46 CET 2003 Paolo Molaro <lupus@ximian.com>
5882
5883         * loader.c: fixed off by one error in loaded parameter names.
5884
5885 2003-01-08  Dietmar Maurer  <dietmar@ximian.com>
5886
5887         * marshal.c (mono_marshal_get_icall_wrapper): like
5888         mono_marshal_get_native_wrapper, but simpler and use a MonoMethodSignature
5889         instead of a MonoMethod.
5890
5891 2003-01-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5892
5893         * decimal.c: fixed bug #36537.
5894
5895 Mon Jan 6 19:37:59 CET 2003 Paolo Molaro <lupus@ximian.com>
5896
5897         * marshal.c: throw a missing method exception if a
5898         P/Invoke method is not found.
5899
5900 Sun Jan 5 11:57:09 CET 2003 Paolo Molaro <lupus@ximian.com>
5901
5902         * icall.c: allow a null this for constructors.
5903
5904 Sat Jan 4 18:28:42 CET 2003 Paolo Molaro <lupus@ximian.com>
5905
5906         * icall.c: raise the proper exceptions if the arguments to the
5907         internal Invoke are incorrect.
5908
5909 2003-01-03  Dietmar Maurer  <dietmar@ximian.com>
5910
5911         * marshal.c (mono_marshal_get_ptr_to_struct): code cleanups
5912
5913 2003-01-03  Martin Baulig  <martin@ximian.com>
5914
5915         * debug-mono-symfile.h: Increment MONO_SYMBOL_FILE_DYNAMIC_VERSION.
5916
5917 2002-12-31  Martin Baulig  <martin@ximian.com>
5918
5919         * debug-mono-symfile.c: Completely rewrote the type section.
5920         Instead of using individual malloc()ed fields, we use one big
5921         continuous memory area and offsets into this area.
5922         See the comments in the source code for details.
5923
5924 2002-12-30  Martin Baulig  <martin@ximian.com>
5925
5926         * debug-mono-symfile.h (MonoDebugTypeInfo): Renamed to MonoDebugClassInfo.
5927
5928 2002-12-30  Martin Baulig  <martin@ximian.com>
5929
5930         * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Include the
5931         line number table in this data blob instead of using an external
5932         pointer.
5933
5934 2002-12-28  Martin Baulig  <martin@ximian.com>
5935
5936         * debug-mono-symfile.h: Increment MONO_SYMBOL_FILE_DYNAMIC_VERSION.
5937
5938 2002-12-22  Rachel Hestilow  <hestilow@ximian.com>
5939
5940         * marshal.c (mono_marshal_get_runtime_invoke): Support MONO_TYPE_CHAR
5941         as a boxed return type.
5942
5943 2002-12-21  Miguel de Icaza  <miguel@ximian.com>
5944
5945         * appdomain.c
5946         (ves_icall_System_AppDomainSetup_InitAppDomainSetup): Use
5947         g_build_filename to properly get separators on the filename created.
5948
5949         * object.h: Small change, introduce MonoMarshalByRefObject to
5950         track the layout of that structure in the C# universe as we make
5951         changes there.
5952
5953 Thu Dec 19 16:23:19 CET 2002 Paolo Molaro <lupus@ximian.com>
5954
5955         * object.c: removed assert to allow static fields on interfaces.
5956         * loader.c: a TypeSpec may be used for any type, not just arrays.
5957
5958 Thu Dec 19 14:19:42 CET 2002 Paolo Molaro <lupus@ximian.com>
5959
5960         * class.c, class.h: added mono_class_array_element_size ().
5961         Ignore static methods in interfaces.
5962
5963 2002-12-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5964
5965         * threads.c: fixed the build under cygwin.
5966
5967 Wed Dec 18 18:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
5968
5969         * reflection.c: handle nullref constants. Allocate keys for
5970         reflection handles with the GC.
5971
5972 Wed Dec 18 11:34:18 CET 2002 Paolo Molaro <lupus@ximian.com>
5973
5974         * threads.c, threads.h: added mono_thread_get_abort_signal()
5975         to get a suitable signal for thread abort.
5976
5977 Wed Dec 18 11:26:18 CET 2002 Paolo Molaro <lupus@ximian.com>
5978
5979         * metadata.c: fix handling of ExportedType table.
5980
5981 2002-12-15  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5982
5983         * icall.c: added WriteWindowsDebugString internal call.
5984
5985 2002-12-15  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5986
5987         * reflection.h: added fields to match C# implementation.
5988
5989 2002-12-14  Gonzalo Paniagua Javier <gonzalo@ximian.com>
5990
5991         * icall.c: patch from Jaroslaw Kowalski to fix Environment.MachineName.
5992
5993 2002-12-12  Juli Mallett  <jmallett@FreeBSD.org>
5994
5995         * gc.h, gc-internal.h: Rename header for GC internal calls to
5996         gc-internal.h from gc.h as to not clash with Boehm GC having its
5997         header installed as <gc.h> in outside include paths.
5998         * appdomain.c, gc.c, icall.c, object.c: Account for aforementioned.
5999         * threads.c: If SIGRTMIN is not defined, fall back to SIGUSR1.
6000
6001 2002-12-12  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6002
6003         * icall.c: assign minor, build and revision in FillName.
6004
6005 2002-12-11  Zoltan Varga  <vargaz@freemail.hu>
6006
6007         * image.h reflection.h reflection.c class.h class.c loader.c object.c:
6008         Added support for running code generated by Reflection.Emit.
6009
6010 2002-12-11  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6011
6012         * appdomain.c: check for NULL argument in LoadFrom.
6013
6014 2002-12-10  Dick Porter  <dick@ximian.com>
6015
6016         * threads.c: WaitHandle fixes from Tum <tum@veridicus.com>
6017
6018 2002-12-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6019
6020         * appdomain.c: fix buglet when building exe file name.  Handle full
6021         assembly name (needed after latest changes to AssemblyName).
6022         * image.c:
6023         (mono_image_close): free some hashtables.
6024
6025 2002-12-05  Dietmar Maurer  <dietmar@ximian.com>
6026
6027         * threads.c (ves_icall_System_Threading_Thread_Abort): we use SIGRTMIN 
6028         instead of SIGUSR1, because SIGUSR1 is used by the pthread implementation 
6029         on some systems (redhat 7.3) 
6030
6031 Thu Dec 5 16:13:40 CET 2002 Paolo Molaro <lupus@ximian.com>
6032
6033         * threads.c: delete the critical section of a sync block,
6034         spotted and fixed by tum@veridicus.com (Thong (Tum) Nguyen).
6035
6036 Thu Dec 5 12:52:52 CET 2002 Paolo Molaro <lupus@ximian.com>
6037
6038         * pedump.c, cil-coff.h, monosn.c: add strong name cli header flag.
6039
6040 2002-12-05  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6041
6042         * appdomain.[ch]: handle the assembly preload event to try loading the
6043         assemblies using the paths we have in the current domain.
6044
6045         * assembly.[ch]: created an assembly preload hook that is called to try
6046         loading the assembly by other means that the ones provided here.
6047
6048         * domain.c: initialize the domain search path.
6049
6050         From now on, assemblies (TODO: except corlib and System) are loaded
6051         according to these rules when using mono_assembly_load ():
6052
6053                 1. It tries to load the assembly from the ApplicationBase
6054                 of the current domain appending .dll and .exe (TODO: have to
6055                 try loading from name/name.dll and name/name.exe).
6056
6057                 2. It tries the search path specified in PrivateBinPath for the
6058                 current domain (if any).
6059
6060                 3. Previous behavior.
6061
6062 Wed Dec 4 16:02:25 CET 2002 Paolo Molaro <lupus@ximian.com>
6063
6064         * icall.c: implemented GetInterfaceMap() related icall.
6065         * domain.c, loader.h: load MethodInfo in mono_defaults.
6066
6067 Wed Dec 4 11:02:30 CET 2002 Paolo Molaro <lupus@ximian.com>
6068
6069         * gc.c: disable the finalizer thread for now, untill all the issues
6070         with it are resolved.
6071
6072 Wed Dec 4 10:44:01 CET 2002 Paolo Molaro <lupus@ximian.com>
6073
6074         * string-icalls.c: handle embedded nulls in string ctor when the
6075         length is specified.
6076
6077 Tue Dec 3 19:29:20 CET 2002 Paolo Molaro <lupus@ximian.com>
6078
6079         * class.c: look for explicit interface implementation in parent
6080         classes, too.
6081
6082 2002-12-03  Dietmar Maurer  <dietmar@ximian.com>
6083
6084         * gc.c (run_finalize): dont run the finalizer (strange behaviour on rh7.3) 
6085
6086 Tue Dec 3 12:40:06 CET 2002 Paolo Molaro <lupus@ximian.com>
6087
6088         * gc.c: protect handles with a critical section.
6089
6090 2002-12-02  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6091
6092         * icall.c:
6093         (ves_icall_type_from_name): it now has throwOnError and ignoreCase
6094         parameters. If no assembly specified, try getting the type from all
6095         the assemblies in the current domain, else, load the assembly and get
6096         the type from it.
6097
6098 2002-11-30  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6099
6100         * marshal.c: applied patch from Aleksey Demakov that fixes
6101         ves_icall_System_Runtime_InteropServices_Marshal_PtrToStringUni.
6102
6103 2002-11-28  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6104
6105         * icall.c: fixed get_location.
6106
6107 2002-11-28  Dietmar Maurer  <dietmar@ximian.com>
6108
6109         * icall.c: moved MONO_ARCH_SAVE_REGS to the end of the
6110         declarations to make it work with older gcc. 
6111
6112         * loader.c (mono_get_method): set signature->pinvoke for native calls
6113
6114 2002-11-20  Dick Porter  <dick@ximian.com>
6115
6116         * threads.c (mono_thread_init): Set the main thread's handle
6117
6118 Tue Nov 19 14:15:34 CET 2002 Paolo Molaro <lupus@ximian.com>
6119
6120         * gc.c: allow compilation without GC support. Changed to match the
6121         mono coding style.
6122
6123 Mon Nov 18 18:41:51 CET 2002 Paolo Molaro <lupus@ximian.com>
6124
6125         * gc.c: don't start the finalizer thread if the env var GC_DONT_GC is set.
6126
6127 Mon Nov 18 16:35:22 CET 2002 Paolo Molaro <lupus@ximian.com>
6128
6129         * reflection.c: set a public key token on the core assemblies.
6130
6131 2002-11-18  Dick Porter  <dick@ximian.com>
6132
6133         * threads.c: Split out some thread initialisation so that other
6134         files can set the start callback function.
6135
6136         * gc.c: Run finalisers in a separate thread, to avoid stack
6137         overflow.  Fixes bug 31333.
6138
6139         * appdomain.c: Set up GC finalisation thread.
6140
6141         * reflection.c: 
6142         * object.c: 
6143         * domain.c: Use gc.h macros for GC_malloc
6144         
6145 2002-11-15  Dick Porter  <dick@ximian.com>
6146
6147         * threadpool.c: 
6148         * threads.c:
6149         * appdomain.c: Removed mono_runtime_init_with_attach(),
6150         mono_thread_create_arg(), and mono_thread_init_with_attach(), by
6151         merging the extra parameter with the existing function.  Removed
6152         unneeded code in mono_thread_attach().
6153
6154 2002-11-14  Dietmar Maurer  <dietmar@ximian.com>
6155
6156         * image.c (mono_image_loaded_by_guid): a method to get loaded
6157         images by guid. 
6158         (load_metadata_ptrs): we store the guid as string.
6159
6160 2002-11-11  Dietmar Maurer  <dietmar@ximian.com>
6161
6162         * assembly.c (mono_assembly_open): check the guid of aot compiled lib.
6163
6164         * metadata.c (mono_guid_to_string): imported method form Zoltan
6165         Varga (slightly modified)
6166
6167         * assembly.c (mono_assembly_open): load precompiled code
6168
6169         * loader.h (MonoMethod): we store the method token for use in the
6170         aot compiler. 
6171
6172 2002-11-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6173
6174         * appdomain.c: insert the loaded assemblies in the domain->assemblies in
6175         the hook function called when an assembly is loaded.
6176         
6177         * domain.c: Modified file.
6178         (mono_domain_assembly_load): removed hash table insertion of assemblies.
6179
6180         Fixes bug #33196.
6181
6182 2002-11-07  Miguel de Icaza  <miguel@ximian.com>
6183
6184         * reflection.c: Map PEFileKind to the value expected by the WinNT
6185         image loader. 
6186
6187 2002-11-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6188
6189         * rand.c: use /dev/urandom. If it fails to open, use the previous one.
6190         Read until the buffer is filled completely.
6191
6192 2002-11-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6193
6194         * icall.c: implemented MonoType.InternalGetEvent ().
6195
6196 2002-11-04  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6197
6198         * appdomain.c: implemented InitAppDomainSetup. Delayed
6199         AppDomain.SetupInformation until mono_runtime_exec_main, where we get
6200         the entry_assembly.
6201
6202         * assembly.c: base_dir is now an absolute path ending with
6203         G_DIR_SEPARATOR.
6204
6205         * icall.c: modified get_location according to the above changes.
6206
6207         * object.c: init AppDomain.SetupInformation for the default domain after
6208         we have the entry assembly.
6209
6210         * domain.c: when unloading a domain, setup = NULL.
6211
6212 2002-11-04  Dietmar Maurer  <dietmar@ximian.com>
6213
6214         * marshal.c (emit_ptr_to_str_conv): try to fix bug 29548
6215
6216 Sun Nov 3 15:39:28 CET 2002 Paolo Molaro <lupus@ximian.com>
6217
6218         * object.h, object.c: introduced mono_object_get_virtual_method ()
6219         to lookup the method invoked on an object when a callvirt is done on
6220         a method.
6221         * icall.c: make MethodInfo::Invoke() always do a virtual call.
6222
6223 2002-11-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6224
6225         * appdomain.c: invoke AssemblyLoad and AsemblyResolve events in the
6226         current domain when loaded an assembly and failed to load it.
6227
6228         * icall.c: changed ...Assembly_GetType to Assembly_InternalGetType.
6229
6230 2002-10-31  Dick Porter  <dick@ximian.com>
6231
6232         * icall.c: 
6233         * file-io.h: 
6234         * file-io.c: Return the error status in a parameter, as the
6235         GetLastError() value has long since been blown away if we try and
6236         look it up in a subsequent internal call invocation.  Delete the
6237         GetLastError() internal call, because it's useless.
6238
6239 2002-10-31  Dietmar Maurer  <dietmar@ximian.com>
6240
6241         * class.[ch]: added cast_class to fix bug 29517
6242
6243 Wed Oct 30 19:37:32 CET 2002 Paolo Molaro <lupus@ximian.com>
6244
6245         * marshal.c: create valid IL code in the filter clause:
6246         the new JIT is less forgiving:-)
6247
6248 2002-10-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6249
6250         * icall.c: removed get_property internal call.
6251
6252 2002-10-25  Zoltan Varga  <vargaz@freemail.hu>
6253
6254         * appdomain.h domain.c: Added an ID to appdomains.
6255         
6256         * threads.c threads.h icall.c: Implement icall
6257         Thread:GetDomainID(), and remove unused icall 
6258         CurrentThreadDomain_internal.
6259
6260 2002-10-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6261
6262         * icall.c: Don't recurse through the base types in GetConstructor.
6263         Fixes bug #32063. 
6264
6265 Thu Oct 24 16:56:00 CEST 2002 Paolo Molaro <lupus@ximian.com>
6266
6267         * mempool.h, mempool.c: added mono_mempool_empty() and
6268         mono_mempool_stats().
6269
6270 2002-10-23  Dick Porter  <dick@ximian.com>
6271
6272         * file-io.c: 
6273         * file-io.h: 
6274         * icall.c: Added MonoIO.GetFileType internal call
6275
6276 2002-10-17  Dick Porter  <dick@ximian.com>
6277
6278         * appdomain.c (mono_runtime_cleanup): Don't signal the async
6279         delegate semaphore before waiting for all threads to finish,
6280         because new threads can also call async delegates.  Fixes bug
6281         32004.
6282
6283         * threadpool.c (async_invoke_thread): Only wait for 500ms instead
6284         of 3 seconds, in case another async job is queued.  (This part is
6285         needed because the bug fix reintroduced the 3s exit lag.)  This
6286         makes the mono_runtime_shutdown flag superfluous.
6287
6288 Thu Oct 17 13:11:39 CEST 2002 Paolo Molaro <lupus@ximian.com>
6289
6290         * reflection.c: include ehader size in method section headers.
6291         Really check for suplicated modules entries.
6292
6293 2002-10-17  Martin Baulig  <martin@gnome.org>
6294
6295         * debug-mono-symfile.c: Added back support for locals.
6296
6297 2002-10-14  Martin Baulig  <martin@gnome.org>
6298
6299         * debug-mono-symfile.c: Added MONO_TYPE_I, MONO_TYPE_U and
6300         MONO_TYPE_VOID.
6301
6302 2002-10-14  Martin Baulig  <martin@gnome.org>
6303
6304         * debug-mono-symfile.c (ves_icall_MonoDebugger_GetType): Use
6305         mono_class_get() instead of looking in the class cache. 
6306
6307 2002-10-13  Martin Baulig  <martin@gnome.org>
6308
6309         * debug-mono-symfile.c: Set version number to 28, include the
6310         signature in method names.
6311
6312 2002-10-13  Martin Baulig  <martin@gnome.org>
6313
6314         * debug-mono-symfile.h: Set version number to 27.
6315
6316 2002-10-11  Martin Baulig  <martin@gnome.org>
6317
6318         * gc.c: Don't register/unregister NULL pointers as disappearing links.
6319
6320 Thu Oct 10 14:56:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
6321
6322         * metadata.c, metadata.h: added helper function to allocate signatures.
6323
6324 2002-10-09  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6325
6326         * icall.c: added internal call to get the location of machine.config.
6327
6328 2002-10-08  Martin Baulig  <martin@gnome.org>
6329
6330         * debug-mono-symfile.c: Ignore classes with a pending init for the
6331         moment.
6332
6333 2002-10-03  Dick Porter  <dick@ximian.com>
6334
6335         * threads.c: Freebsd pthread_t is a pointer
6336
6337 2002-10-03  Dick Porter  <dick@ximian.com>
6338
6339         * socket-io.c: Implemented GetHostName_internal
6340
6341 2002-10-02  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6342
6343         * mono-config.c:
6344         (mono_config_parse_file): don't leak the text.
6345
6346 2002-10-02  Martin Baulig  <martin@gnome.org>
6347
6348         * debug-mono-symfile.c: Added support for methods.
6349
6350 2002-10-01  Martin Baulig  <martin@gnome.org>
6351
6352         * debug-mono-symfile.c: Don't emit methods and line numbers for
6353         the dynamic symbol file, just write the type table.  We can easily
6354         have an external helper program which creates a symbol file for an
6355         IL file.        
6356
6357 2002-10-01  Dick Porter  <dick@ximian.com>
6358
6359         * threads.c (ves_icall_System_Threading_Thread_Start_internal):
6360         Only add the handle to the cleanup array when we're about to
6361         launch the thread.  Bug 31425 deadlocked when the test was run on
6362         mono under w32.
6363
6364 2002-10-01  Martin Baulig  <martin@gnome.org>
6365
6366         * debug-mono-symfile.c: Added support for properties.
6367
6368 Fri Sep 27 18:55:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
6369
6370         * reflection.c: unaligned store fix from Mark Crichton
6371         <crichton@gimp.org>.
6372
6373 2002-09-27  Martin Baulig  <martin@gnome.org>
6374
6375         * icall.c ("System.Reflection.Assembly::GetReferencedAssemblies"):
6376         New interncall.
6377
6378 Fri Sep 27 15:38:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
6379
6380         * assembly.h, assembly.c: use a sane API to hook into the assembly
6381         loading process instead of a useless special-purpouse hack
6382         (ngen needs a hook, too, for example).
6383
6384 2002-09-27  Dick Porter  <dick@ximian.com>
6385
6386         * threads.c (mono_thread_init): Call GetCurrentProcess() so
6387         io-layer can set up some process handle info.  Not needed on w32,
6388         but doesn't hurt either.
6389
6390         * process.c: Pass the program name in the second parameter to
6391         CreateProcess, so the path is searched.  Include the working
6392         directory. Implemented process name, process enumeration, and some
6393         process detail internal calls.
6394         
6395         * icall.c: Added internal calls for process lookup, and some
6396         process details
6397
6398 2002-09-26  Martin Baulig  <martin@gnome.org>
6399
6400         * assembly.c (mono_install_open_assembly_hook): New global
6401         function to install a function to be invoked each time a new
6402         assembly is loaded.
6403         (mono_assembly_open): Run this callback function if set.
6404
6405         * debug-mono-symfile.c: Put back line numbers for the dynamic
6406         symbol file and also record the .il file as source file.  This
6407         allows us to install the temporary symbol file as `file.dbg' just
6408         like a compiler-generated one.
6409
6410 2002-09-26  Nick Zigarovich <nick@chemlab.org>
6411
6412         * Corrected typo in gc.c (BOHEM vs BOEHM).
6413
6414 2002-09-25  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6415
6416         * icall.c: fixed bug #31235 by copying a few lines from GetMethods to
6417         GetProperties. Also avoid calling g_slist_length in GetProperties and
6418         GetMethods.
6419
6420 Wed Sep 25 22:18:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
6421
6422         * reflection.c: avoid unaligned stores (bug spotted by
6423         Mark Crichton  <crichton@gimp.org>).
6424
6425 2002-09-25  Martin Baulig  <martin@gnome.org>
6426
6427         * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Use pointers
6428         instead of guint64 for addresses and added prologue/epilogue info.
6429
6430 2002-09-25  Martin Baulig  <martin@gnome.org>
6431
6432         * debug-mono-symfile.h (MonoDebugLineNumberEntry): New type to
6433         store line number info.  For the dynamic symbol file, we only need
6434         to provide the JIT generated dynamic line number info for the dynamic
6435         symbol file.
6436
6437 2002-09-25  Martin Baulig  <martin@gnome.org>
6438
6439         * debug-mono-symfile.h: Incremented version number.
6440
6441 2002-09-24  Martin Baulig  <martin@gnome.org>
6442
6443         * class.c (mono_debugger_class_init_func): New global function
6444         pointer variable.
6445         (mono_class_init): If mono_debugger_class_init_func is non-NULL,
6446         call it.
6447
6448         * debug-mono-symfile.c (mono_debug_symfile_add_type): New
6449         function.  This is called via the mono_debugger_class_init_func
6450         hook to add all types to the dynamic type table.
6451         (ves_icall_MonoDebugger_GetType): New interncall to get a class
6452         from its metadata token.
6453
6454         * icall.c ("System.Reflection.Assembly::MonoDebugger_GetType"):
6455         New interncall for the debugger.
6456
6457 2002-09-24  Nick Drochak <ndrochak@gol.com>
6458
6459         * icall.c (ves_icall_System_Enum_ToObject): validate the type parameter
6460         before using it in case it is null.
6461         
6462 Tue Sep 24 13:24:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
6463
6464         * metadata.c: allow custom modifiers in local var signatures
6465         (bug spotted by Zoltan Varga).
6466
6467 Tue Sep 24 12:12:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
6468
6469         * class.c: deal with the <Module> class that may have a NULL vtable.
6470         Eliminate warnings.
6471
6472 Tue Sep 24 11:28:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
6473
6474         * image.c, image.h: more strong name helpers.
6475         * monosn.c: more work: convert pem keys to cryptoapi format.
6476
6477 Tue Sep 24 11:27:38 CEST 2002 Paolo Molaro <lupus@ximian.com>
6478
6479         * string-icalls.c: speedup IndexOf.
6480
6481 Tue Sep 24 11:17:13 CEST 2002 Paolo Molaro <lupus@ximian.com>
6482
6483         * icall.c: updates from Zoltan.2.Varga@nokia.com.
6484
6485 Tue Sep 24 11:09:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
6486
6487         * icall.c: cleanup: use mono_object_domain ().
6488
6489 2002-09-23  Martin Baulig  <martin@gnome.org>
6490
6491         * debug-mono-symfile.c: Improved type support.
6492
6493 2002-09-22  Martin Baulig  <martin@gnome.org>
6494
6495         * debug-mono-symfile.c: Added support for reference types and strings.
6496
6497 2002-09-22  Martin Baulig  <martin@gnome.org>
6498
6499         * debug-mono-symfile.c: Started to work on the type table.
6500
6501 2002-09-21  Martin Baulig  <martin@gnome.org>
6502
6503         * debug-mono-symfile.c: Largely reworked the symbol table format.
6504         The symbol table is now incrementally updated each time a new
6505         method is added.  We're now also using our own magic and version
6506         so that you don't need to recompile all your classes if the
6507         dynamic table changes.
6508         (mono_debug_update_mono_symbol_file): Removed.
6509         (mono_debug_symfile_add_method): New function to add a method.
6510
6511 2002-09-21  Martin Baulig  <martin@gnome.org>
6512
6513         * icall.c
6514         ("System.Reflection.Assembly::MonoDebugger_GetLocalTypeFromSignature"):
6515         New interncall.
6516
6517         * debug-mono-symfile.c (ves_icall_MonoDebugger_GetLocalTypeFromSignature):
6518         New interncall to get a method from its metadata token.
6519
6520 2002-09-21  Martin Baulig  <martin@gnome.org>
6521
6522         * debug-mono-symfile.c: Create type table.
6523
6524 2002-09-20  Martin Baulig  <martin@gnome.org>
6525
6526         * debug-mono-symfile.c: Reflect latest Mono.CSharp.Debugger changes.
6527
6528 2002-09-20  Martin Baulig  <martin@gnome.org>
6529
6530         * debug-mono-symfile.c: Provide information about params and locals.
6531
6532 2002-09-20  Martin Baulig  <martin@gnome.org>
6533
6534         * icall.c ("System.Reflection.Assembly::MonoDebugger_GetMethod"):
6535         New interncall.
6536
6537         * debug-mono-symfile.c (ves_icall_MonoDebugger_GetMethod): New
6538         interncall to get a method from its metadata token.
6539
6540 2002-09-20  Martin Baulig  <martin@gnome.org>
6541
6542         * debug-mono-symfile.c: Added a few checks for method->header
6543         being non-NULL.  This should never happen, but for the moment
6544         let's use a g_warning() rather than a g_assert().
6545
6546 2002-09-19  Mark Crichton  <crichton@gimp.org>
6547
6548         * gc.c: ves_icall_System_GCHandle_FreeHandle made a call to libgc
6549         even if support for it isn't present.  Added an #ifdef to fix this.
6550
6551         * socket-io.c: Added checks back for Solaris support.
6552
6553 2002-09-19  Martin Baulig  <martin@gnome.org>
6554
6555         * debug-mono-symfile.c (read_string, write_string): Reflect latest
6556         changes in the symbol file format.
6557
6558 2002-09-18  Martin Baulig  <martin@gnome.org>
6559
6560         * debug-mono-symfile.c: Set version number to 21.
6561
6562 2002-09-18  Dick Porter  <dick@ximian.com>
6563
6564         * threads.c (mon_new): Use the GC_MALLOC macro to hide differences
6565         on netbsd.  Fixes bug 30051.
6566
6567 2002-09-17  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6568
6569         * reflection.c:
6570         (set_version_from_string): little fix.
6571
6572 Mon Sep 16 18:57:13 CEST 2002 Paolo Molaro <lupus@ximian.com>
6573
6574         * monosn.c, Makefile.am: added strong name utility.
6575         * reflection.h, reflection.c: implemented delayed signing,
6576         locale, version and hash id assembly attributes.
6577
6578 Mon Sep 16 18:51:47 CEST 2002 Paolo Molaro <lupus@ximian.com>
6579
6580         * loader.c, metadata.c: load param attributes in signatures.
6581
6582 2002-09-16  Martin Baulig  <martin@gnome.org>
6583
6584         * debug-mono-symfile.c: Added string table with all method names.
6585
6586 2002-09-14  Martin Baulig  <martin@gnome.org>
6587
6588         * debug-mono-symfile.h (MonoSymbolFile): Added method range table for
6589         fast method lookup.
6590
6591 Fri Sep 13 16:04:54 CEST 2002 Paolo Molaro <lupus@ximian.com>
6592
6593         * reflection.c: record the public key token of referenced assemblies.
6594
6595 Fri Sep 13 15:41:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
6596
6597         * image.c, image.h: added functions to get the strong name and the
6598         public key of an assembly.
6599         * pedump.c: use them.
6600
6601 2002-09-12  Dietmar Maurer  <dietmar@ximian.com>
6602
6603         * marshal.c (emit_str_to_ptr_conv): support marshalling of delegates.
6604
6605 2002-09-12  Miguel de Icaza  <miguel@ximian.com>
6606
6607         * marshal.c (mono_marshal_get_managed_wrapper): Added
6608         MONO_TYPE_BOOLEAN 
6609
6610 2002-09-11  Martin Baulig  <martin@gnome.org>
6611
6612         * gc.c: Call GC_unregister_disappearing_link() on all links when
6613         finalizing them, this is necessary to aviod a crash in boehm's
6614         finalize handler.
6615
6616 Wed Sep 11 17:06:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
6617
6618         * gc.c: handle GetTarget for finalized objects spotted and fixed by
6619         nick@chemlab.org.
6620
6621 Wed Sep 11 15:27:20 CEST 2002 Paolo Molaro <lupus@ximian.com>
6622
6623         * icall.c: implemented MonoType::Module.
6624         * reflection.c, reflection.h: mono_module_get_object () from
6625         Tomi Pakarinen <tomi.pakarinen@welho.com>.
6626
6627 Wed Sep 11 12:53:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
6628
6629         * icall.c: ignore overridden methods in GetMethods ().
6630         Fix for FieldInfo::SetValue().
6631         * object.c: handle float/double in runtime invoke.
6632
6633 Tue Sep 10 15:51:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
6634
6635         * object.c: allow a constructor to be called again on an object.
6636
6637 Tue Sep 10 11:58:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
6638
6639         * class.h, class.c: move field layout code to it's own function and
6640         export it. Get an interface id earlier. Move fields in MonoClass
6641         so they are more cache friendly and align the bitfields.
6642         * loader.c: temporary handle get_param_names() for a runtime method.
6643         * reflection.c, reflection.h: more code to handle runtime creation of
6644         types.
6645
6646 2002-09-09  Martin Baulig  <martin@gnome.org>
6647
6648         * marshal.c (mono_marshal_get_native_wrapper): We need to use a special
6649         signature with the pinvoke field being set for the actual call.
6650
6651 Sat Sep 7 10:12:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
6652
6653         * icall.c: removed some unused icalls. Start of map of glib charsets
6654         to corlib names. Implemented RuntimeMethod::GetFunctionPointer ().
6655
6656 Fri Sep 6 16:08:44 CEST 2002 Paolo Molaro <lupus@ximian.com>
6657
6658         * debug-helpers.c: break infinite loop (found and fixed by
6659         Holger Arnold <harnold@gmx.de>).
6660
6661 Thu Sep 5 18:50:54 CEST 2002 Paolo Molaro <lupus@ximian.com>
6662
6663         * icall.c: target may be null in create_delegate.
6664
6665 Thu Sep 5 17:42:13 CEST 2002 Paolo Molaro <lupus@ximian.com>
6666
6667         * marshal.c: handle a boolean return type.
6668
6669 Thu Sep 5 13:09:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
6670
6671         * gc.c: put HIDE_POINTER/REVEAL_POINTER only here.
6672
6673 Wed Sep 4 19:23:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
6674
6675         * gc.c: fix weakreferences.
6676
6677 Wed Sep 4 13:59:50 CEST 2002 Paolo Molaro <lupus@ximian.com>
6678
6679         * icall.c: added icall to get default codepage.
6680
6681 2002-09-03  Dick Porter  <dick@ximian.com>
6682
6683         * threads.h: 
6684         * threads.c: Use MonoThread instead of MonoObject where
6685         apropriate.
6686
6687         Store running thread objects in a hash table, so that we have all
6688         the info to hand when waiting for them to finish
6689         (means we don't need OpenThread() any more, so mingw builds should
6690         be fully functional again.)
6691
6692         * verify.c:
6693         * object.h: Added thread ID to MonoThread
6694
6695 2002-09-03  Martin Baulig  <martin@gnome.org>
6696
6697         * icall.c (System.Reflection.Assembly::get_location): New interncall.
6698
6699 2002-09-03  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6700
6701         * icall.c: fixed leak in get_temp_path. Thanks lupus.
6702
6703 2002-09-03  Martin Baulig  <martin@gnome.org>
6704
6705         * debug-helpers.c (mono_disasm_code_one): Added `const guchar **endp'
6706         argument to store the end address of the disassembled instruction.
6707
6708         * debug-mono-symfile.h (MonoDebugMethodInfo, MonoDebugVarInfo): Moved
6709         here from debug-symfile.h.
6710         (MonoDebugMethodJitInfo): Moved all fields which are filled out by the
6711         JIT into this struct.
6712         (MonoSymbolFile): Added `char *image_file' field.
6713         (MonoDebugGetMethodFunc): Removed.
6714         (mono_debug_update_mono_symbol_file): Removed the hash table argument.
6715         (mono_debug_create_mono_symbol_file): Removed the `source_file' argument.
6716         (mono_debug_find_method): New method.
6717
6718         * debug-mono-symfile.c (mono_debug_create_mono_symbol_file): Always
6719         create a full symbol file.
6720         (mono_debug_update_mono_symbol_file): Don't distinguish between dynamic
6721         and static symbol files.
6722         (mono_debug_find_method): The symbol file keeps an internal method hash,
6723         call this to get a MonoDebugMethodInfo from a MonoMethod.
6724
6725         * debug-symfile.[ch]: Removed.
6726
6727 2002-08-29  Miguel de Icaza  <miguel@ximian.com>
6728
6729         * image.c (do_mono_image_open): Remove linker version check.
6730
6731 2002-08-29  Dietmar Maurer  <dietmar@ximian.com>
6732
6733         * marshal.c (mono_marshal_get_managed_wrapper): don't cache
6734         wrappers for instance methods.
6735         
6736 2002-08-29  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6737
6738         * icall.c: added ves_icall_System_IO_Path_get_temp_path.
6739
6740 2002-08-28  Dick Porter  <dick@ximian.com>
6741
6742         * Makefile.am: Export HOST_CC for w32 builds
6743
6744 Tue Aug 27 18:34:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
6745
6746         * file-io.c process.c: MonoString are null terminated, no
6747         need for mono_string_to_utf16() anymore.
6748
6749 Tue Aug 27 17:51:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
6750
6751         * icall.c, unicode.h, unicode.c: removed unused iconv stuff.
6752
6753 Tue Aug 27 16:38:58 CEST 2002 Paolo Molaro <lupus@ximian.com>
6754
6755         * icall.c, reflection.h: speedup System.MonoType.
6756
6757 Tue Aug 27 16:37:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
6758
6759         * reflection.c: allow null as the value of a string argument in
6760         custom attributes constructors.
6761
6762 2002-08-27  Martin Baulig  <martin@gnome.org>
6763
6764         * debug-mono-symfile.h (MonoSymbolFileMethodAddress): Removed the
6765         `trampoline_address' field.
6766
6767 2002-08-27  Dietmar Maurer  <dietmar@ximian.com>
6768
6769         * marshal.c (mono_marshal_get_native_wrapper): removed wrong null
6770         check (fixes bug #29486) 
6771
6772 2002-08-27  Martin Baulig  <martin@gnome.org>
6773
6774         * debug-mono-symfile.c: Changed the file format in a way that allows us
6775         open it read-only and to use a specially malloced area for all the
6776         dynamic data.  We can now also generate a symbol file on-the-fly if we're
6777         debugging IL code and there is no MCS generated symbol file for it.
6778
6779 Mon Aug 26 16:47:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
6780
6781         * object.c: added a define for a good string and array
6782         creation speedup (not enabled by default because we need to deal with
6783         the synch stuff).
6784
6785 2002-08-26  Martin Baulig  <martin@gnome.org>
6786
6787         * debug-mono-symfile.c (mono_debug_create_mono_symbol_file): New
6788         function to create a dynamic symbol file.  This is used by the
6789         debugger to create a symbol file for IL code on-the-fly.
6790
6791 2002-08-26  Martin Baulig  <martin@gnome.org>
6792
6793         * loader.c (mono_lookup_pinvoke_call): Include the error message
6794         from g_module_error() in the error message.
6795
6796 2002-08-24  Martin Baulig  <martin@gnome.org>
6797
6798         * debug-mono-symfile.c (mono_debug_update_mono_symbol_file): New
6799         function to update the symbol file.  The symbol file is mmap()ed
6800         writable, but private.  This allows us to install the symbol file
6801         together with the assembly.
6802
6803 2002-08-24  Martin Baulig  <martin@gnome.org>
6804
6805         * debug-mono-symfile.[ch]: New files.  Similar to debug-symfile.[ch]
6806         but they can read the new symbol file format which mcs is now creating.
6807
6808         * debug-symfile.c (mono_debug_find_source_location): Moved to
6809         debug-mono-symfile.c; this is now operating on the new symbol file.
6810
6811 2002-08-23  Martin Baulig  <martin@gnome.org>
6812
6813         * debug-helpers.c (mono_method_desc_from_method): New function to get
6814         a MonoMethodDesc from a MonoMethod.
6815
6816 Fri Aug 23 15:54:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
6817
6818         * object.c: fixes assertion failure caused by multiple ExecuteAssembly
6819         calls for same domain (patch by Tomi Pakarinen <Tomi.Pakarinen@iki.fi>).
6820
6821 Fri Aug 23 12:14:45 CEST 2002 Paolo Molaro <lupus@ximian.com>
6822
6823         * string-icalls.[ch]: make helper methods static.
6824
6825 2002-08-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6826
6827         * icall.c: re-applied patch to GetValueInternal. Also added R4 and R8
6828         types to it and to SetValueInternal.
6829
6830         * object.c: Moved handle_enum label to its proper place. This was the
6831         f... bug! ;-)
6832
6833         This time i compiled mcs and gtk-sharp and they both work.
6834
6835 2002-08-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6836
6837         * icall.c: reverted partially my previous patch until 
6838         object.c:set_value handles enums correcly.
6839
6840 2002-08-22  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6841
6842         * icall.c:
6843         (ves_icall_MonoField_GetValue): changed to use mono_field_get_value.
6844         (ves_icall_System_Environment_get_MachineName): removed warning when
6845         compiling under cygwin.
6846
6847 Thu Aug 22 18:49:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
6848
6849         * object.c: fixed field_get_value() for reference types.
6850
6851 2002-08-22  Dick Porter  <dick@ximian.com>
6852
6853         * socket-io.c (ves_icall_System_Net_Sockets_Socket_RecvFrom_internal):
6854         Don't free a buffer while it's still needed.  Patch from Jonathan
6855         Liger <Jonathan.liger@wanadoo.fr>
6856
6857 2002-08-21  Miguel de Icaza  <miguel@ximian.com>
6858
6859         * icall.c (ves_icall_System_Environment_get_Platform): Add new
6860         internal call.
6861
6862 2002-08-21  Dietmar Maurer  <dietmar@ximian.com>
6863
6864         * icall.c (ves_icall_get_method_info): s/MonoMethod/MonoReflectionMethod/
6865         (ves_icall_get_parameter_info): s/MonoMethod/MonoReflectionMethod/
6866
6867         * marshal.c (mono_marshal_get_remoting_invoke): save lmf, because
6868         we call unmanaged code which throws exceptions.
6869
6870 Wed Aug 21 12:56:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
6871
6872         * appdomain.h: added per-domain entry_assembly.
6873         * appdomain.c: ensure mono_runtime_exec_main () gets non-null
6874         arguments.
6875         * icall.c: Assembly::GetEntryAssembly icall.
6876         * object.c: set domain->entry_assembly in mono_runtime_exec_main().
6877         Changes above from a patch by Tomi Pakarinen <tomi.pakarinen@welho.com>.
6878
6879 Tue Aug 20 15:42:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
6880
6881         * appdomain.h, gc.c: added mono_domain_finalize ().
6882
6883 2002-08-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6884
6885         * object.c:
6886         (mono_print_unhandled_exception): changed g_warning by g_printerr
6887         because g_log has a 1024 characters limit (yeah, i got a big stack
6888         trace). Don't print exception name, that should be in ToString 
6889         returned string.
6890
6891 2002-08-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6892
6893         * icall.c: added ves_icall_FieldInfo_SetValueInternal.
6894         * object.c: added missing MONO_TYPE_ARRAY in mono_runtime_invoke_array.
6895
6896 2002-08-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6897
6898         * object.c:
6899         (mono_print_unhandled_exception): after previous commit, i realized
6900         that MS calls ToString on the exception. I changed this function to
6901         do that. This way we get stack_trace for free.
6902
6903 2002-08-19  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6904
6905         * object.c:
6906         (mono_print_unhandled_exception): invoke Message property instead of
6907         getting 'message' field from Exception. Don't allocate memory for
6908         'trace' and 'message' if not needed.
6909
6910 2002-08-18  Dick Porter  <dick@ximian.com>
6911
6912         * unicode.c: Fix asserts to match Encoder.cs checks
6913
6914 Fri Aug 16 21:42:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
6915
6916         * marshal.c: fix unaligned store issue and a few wrong
6917         opcode argument types.
6918
6919 2002-08-16  Gonzalo Paniagua Javier <gonzalo@ximian.com>
6920
6921         * icall.c: added GetUninitializedObjectInternal internal call.
6922
6923 2002-08-16  Dietmar Maurer  <dietmar@ximian.com>
6924
6925         * appdomain.c (mono_runtime_invoke_in_domain): transfer Exception
6926         to the right domain.
6927
6928 2002-08-14  Dietmar Maurer  <dietmar@ximian.com>
6929
6930         * marshal.c (mono_marshal_get_runtime_invoke): unbox value types
6931
6932         * class.c (class_compute_field_layout): set blittable to false for Strings
6933
6934         * appdomain.c (mono_domain_transfer_object): added support for ISerializable
6935
6936 Wed Aug 14 17:26:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
6937
6938         * appdomain.h, reflection.c, icall.c, object.c, reflection.h:
6939         first chunk of code to create types at runtime. Code to
6940         handle ReflectedType/DeclaringType. Make reflection handles
6941         domain specific.
6942
6943 Wed Aug 14 17:24:21 CEST 2002 Paolo Molaro <lupus@ximian.com>
6944
6945         * class.c: set correct name in arrays.
6946
6947 2002-08-13  Dietmar Maurer  <dietmar@ximian.com>
6948
6949         * appdomain.c (mono_domain_transfer_object): make it work with
6950         valuetypes. bug fixes.
6951
6952 2002-08-12  Dick Porter  <dick@ximian.com>
6953
6954         * object.h: Rename some parameters to avoid c++ keywords (Patch
6955         from Joseph Wenninger <kde@jowenn.at>)
6956
6957 Thu Aug 8 13:04:18 CEST 2002 Paolo Molaro <lupus@ximian.com>
6958
6959         * icall.c: added icall to implement Assembly.GetFile*.
6960
6961 Thu Aug 8 10:18:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
6962
6963         * reflection.h, reflection.c: code to embed managed resources.
6964
6965 Tue Aug 6 17:59:44 CEST 2002 Paolo Molaro <lupus@ximian.com>
6966
6967         * class.c: move all the type size stuff into
6968         class_compute_field_layout().
6969
6970 Tue Aug 6 11:20:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
6971
6972         * class.c: ensure enums have always the correct instance size.
6973         * unicode.c: remove wrong assert.
6974
6975 Mon Aug 5 19:30:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
6976
6977         * assembly.c: fix mem corruption issue.
6978         * image.h, image.c: added mono_image_get_resource () to access
6979         managed resources.
6980         * icall.c: implemented Assembly.EntryPoint property and some
6981         Managed Resources related internalcalls.
6982
6983
6984 Mon Aug 5 18:18:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
6985
6986         * image.c, image.h: impemented mono_image_get_entry_point ().
6987         * appdomain.c: use mono_image_get_entry_point.
6988
6989 Mon Aug 5 13:08:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
6990
6991         * reflection.c: support the object type argument when loading
6992         custom attributes.
6993
6994 2002-08-05  Dietmar Maurer  <dietmar@ximian.com>
6995
6996         * marshal.c (mono_marshal_get_managed_wrapper): add suppport for
6997         String as return type.
6998
6999 Fri Aug 2 21:15:42 CEST 2002 Paolo Molaro <lupus@ximian.com>
7000
7001         * reflection.c: fix encoding of named args for custom attrs to match
7002         the ms implementation. Read them back when instantiating custom
7003         attributes.
7004
7005 2002-08-02  Radek Doulik  <rodo@ximian.com>
7006
7007         * marshal.c (mono_mb_add_data): convert ret value to LE, suggested
7008         by Dietmar as quick fix
7009         (mono_marshal_get_delegate_begin_invoke): use sig->param_count +
7010         16 as stack size, used on more places as quick fix before Dietmar
7011         will fix it properly
7012
7013 Fri Aug 2 17:48:17 CEST 2002 Paolo Molaro <lupus@ximian.com>
7014
7015         * object.h, object.c: added accessors for fields and properties.
7016
7017 Fri Aug 2 17:45:15 CEST 2002 Paolo Molaro <lupus@ximian.com>
7018
7019         * class.c, class.h: made mono_class_get_field_from_name ()
7020         loop on parent types.
7021         Added mono_class_get_property_from_name ().
7022
7023 Fri Aug 2 11:40:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
7024
7025         * class.c, class.h: move the code to setup the type vtable in its own
7026         function so that it can be reused also for types created at runtime.
7027         Eliminate the "class" identifier from the header file.
7028         * reflection.c: setup the vtable for enums so that we can create
7029         objects for use in SetConstant ().
7030
7031 2002-08-02  Dietmar Maurer  <dietmar@ximian.com>
7032
7033         * marshal.c (mono_delegate_to_ftnptr): pass delegate->target
7034         instead of the delegate itself as this pointer (bug #28383)
7035
7036 2002-08-01  Dietmar Maurer  <dietmar@ximian.com>
7037
7038         * marshal.c (mono_marshal_get_managed_wrapper): added return type
7039         conversions.
7040
7041 Wed Jul 31 16:49:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
7042
7043         * loader.c: don't set the pinvoke bit on icalls.
7044
7045 2002-07-31  Dietmar Maurer  <dietmar@ximian.com>
7046
7047         * debug-helpers.c (mono_method_full_name): only print a number to
7048         indicate wrapper type (so that the output is more readable in traces).
7049
7050 2002-07-30  Dietmar Maurer  <dietmar@ximian.com>
7051
7052         * class.c (mono_class_init): include method override patch from Paolo
7053
7054 Tue Jul 30 15:20:08 CEST 2002 Paolo Molaro <lupus@ximian.com>
7055
7056         * icall.c: fixed GetTypeCode().
7057
7058 2002-07-29  Dietmar Maurer  <dietmar@ximian.com>
7059
7060         * threads.c (ves_icall_System_Threading_Thread_Thread_internal):
7061         use real delegate invoke function to make it work with multicast
7062         delegates (fix bug# 28291).
7063
7064 Fri Jul 26 11:58:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
7065
7066         * object.c: load constant strings.
7067
7068 Fri Jul 26 11:36:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
7069
7070         * reflection.c: no magic numbers.
7071         * tabledefs.h: security action enum.
7072
7073 Fri Jul 26 11:22:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
7074
7075         * assembly.c: fix possible memory corruption.
7076
7077 Thu Jul 25 13:58:38 CEST 2002 Paolo Molaro <lupus@ximian.com>
7078
7079         * reflection.h, reflection.c: added support for linking resources.
7080         * verify.c: check we have an updated corlib.
7081
7082 2002-07-25  Dietmar Maurer  <dietmar@ximian.com>
7083
7084         * marshal.c (mono_marshal_get_native_wrapper): correctly marshal
7085         string arrays.
7086         (mono_marshal_string_array): null terminate unmanaged string arrays.
7087         (mono_marshal_get_managed_wrapper): print warning for arrays (not implemented)
7088
7089 Wed Jul 24 13:32:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
7090
7091         * icall.c: Type.GetType () can now return also types from the
7092         calling assembly.
7093
7094 Wed Jul 24 13:04:05 CEST 2002 Paolo Molaro <lupus@ximian.com>
7095
7096         * loader.h, loader.c: stack walking support.
7097         * icall.c: implemented GetCurrentMethod, GetExecutingAssembly,
7098         GetCallingAssembly.
7099
7100 2002-07-24  Dietmar Maurer  <dietmar@ximian.com>
7101
7102         * marshal.c: added optimisations for blittable types 
7103
7104         * class.c (mono_array_class_get): do not set blittable attribute on arrays
7105         (mono_class_setup_mono_type): set blittable attribute for single
7106         and double.
7107
7108         * marshal.c (mono_string_utf8_to_builder): impl.
7109         (mono_string_builder_to_utf8): impl.
7110         (mono_marshal_get_native_wrapper): impl. StringBuilder marshaling
7111
7112 2002-07-23  Dietmar Maurer  <dietmar@ximian.com>
7113
7114         * marshal.c (mono_marshal_get_native_wrapper): impl. byref types
7115         (mono_marshal_get_managed_wrapper): impl. byref types
7116
7117 2002-07-23  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7118
7119         * icall.c:
7120         (search_method): don't display debug message. 
7121
7122 2002-07-22  Dietmar Maurer  <dietmar@ximian.com>
7123
7124         * metadata.c (mono_type_stack_size): removed temporary fix for new gcc
7125
7126 Mon Jul 22 18:17:05 CEST 2002 Paolo Molaro <lupus@ximian.com>
7127
7128         * appdomain.c: set the missing filename when throwing exception.
7129
7130 2002-07-22  Dietmar Maurer  <dietmar@ximian.com>
7131
7132         * metadata.c (mono_type_size): code cleanup
7133         (mono_type_stack_size): removed some test code
7134
7135 2002-07-21  Miguel de Icaza  <miguel@ximian.com>
7136
7137         * appdomain.c (ves_icall_System_Reflection_Assembly_LoadFrom): Use
7138         mono_get_exception_file_not_found now.
7139
7140         * exception.c (mono_exception_from_name_two_strings): New version
7141         that will call a constructor with two string arguments. 
7142         (mono_get_exception_file_not_found): New helper routine, used to
7143         report file-not-found errors.
7144
7145 2002-07-20  Dick Porter  <dick@ximian.com>
7146
7147         * process.h:
7148         * process.c: Pass file handles to CreateProcess
7149         
7150         * icall.c:
7151         * file-io.h:
7152         * file-io.c: Implemented CreatePipe
7153
7154 2002-07-19  Dietmar Maurer  <dietmar@ximian.com>
7155
7156         * metadata.c (mono_get_param_info): set alignment for value types
7157
7158 Fri Jul 19 18:58:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
7159
7160         * appdomain.h, domain.c, threads-types.h: don't include config.h in headers.
7161         Constify mono_domain_assembly_open().
7162         * loader.c: handle null namespace in icalls.
7163
7164 2002-07-19  Dietmar Maurer  <dietmar@ximian.com>
7165
7166         * marshal.c (emit_ptr_to_str_conv): marshal object as structs
7167         (emit_str_to_ptr_conv): marshal object as structs
7168
7169         * metadata.c (mono_type_to_unmanaged): marshal object as structs
7170
7171         * marshal.c (mono_marshal_get_runtime_invoke): support value types
7172
7173 2002-07-18  Dietmar Maurer  <dietmar@ximian.com>
7174
7175         * marshal.c (mono_marshal_get_runtime_invoke): use exception filters
7176         (mono_marshal_get_native_wrapper): we an now return value types
7177
7178 Wed Jul 17 18:21:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
7179
7180         * verify.c: more checks implemented.
7181
7182 2002-07-17  Dietmar Maurer  <dietmar@ximian.com>
7183
7184         * marshal.c (mono_delegate_to_ftnptr): invoke the right method
7185         (fix bug #27695)
7186         (mono_marshal_get_native_wrapper): allow byref arguments
7187         (ves_icall_System_Runtime_InteropServices_Marshal_PtrToStringXXX):
7188         impl. PtrToStringXXX methods
7189         (ves_icall_System_Runtime_InteropServices_Marshal_PtrToStructure_type): impl.
7190         (ves_icall_System_Runtime_InteropServices_Marshal_OffsetOf): impl.
7191         (ves_icall_System_Runtime_InteropServices_Marshal_StringToHGlobalAnsi): impl.
7192         (ves_icall_System_Runtime_InteropServices_Marshal_StringToHGlobalUni): impl.
7193         (ves_icall_System_Runtime_InteropServices_Marshal_DestroyStructure): impl.
7194
7195 Tue Jul 16 19:00:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
7196
7197         * reflection.c: fix buglet in parsing an assembly name.
7198
7199 2002-07-16  Dietmar Maurer  <dietmar@ximian.com>
7200
7201         * marshal.c (emit_ptr_to_str_conv): first impl.
7202
7203 Tue Jul 16 12:39:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
7204
7205         * object.c, class.h: cache the vtable in the class as suggested by
7206         vargaz@freemail.hu (Zoltan Varga).
7207
7208 Tue Jul 16 11:27:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
7209
7210         * class.h, loader.c: added mono_field_from_token().
7211         * verify.c: first cut of type checking code.
7212
7213 2002-07-16  Dietmar Maurer  <dietmar@ximian.com>
7214
7215         * marshal.c (mono_marshal_get_native_wrapper): support valuetypes
7216
7217 2002-07-15  Dietmar Maurer  <dietmar@ximian.com>
7218
7219         * marshal.c (mono_marshal_get_native_wrapper): handle enum types
7220         (fix bug #27782)
7221         (mono_marshal_get_remoting_invoke): impl.
7222         (mono_delegate_begin_invoke): impl.
7223         (mono_mb_emit_save_args): impl.
7224         (mono_delegate_end_invoke): impl.
7225         (mono_marshal_get_delegate_begin_invoke):
7226         (mono_marshal_get_delegate_end_invoke):
7227         (mono_marshal_get_delegate_invoke): generate a special name for
7228         those methods (including the signature) and associate them whith
7229         the delegate class. 
7230
7231 2002-07-13  Gonzalo Paniagua Javier <gonzalo@gnome-db.org>
7232
7233         * reflection.[ch]: 
7234         (mono_reflection_type_from_name): now it has a MonoImage parameter
7235         which is used as the default image to search the type in. If the image
7236         is NULL or getting the type from it fails, it defaults to corlib.
7237
7238         * icall.c: changed 1 call to mono_reflection_type_from_name to match
7239         new parameter.
7240
7241 Sat Jul 13 19:32:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
7242
7243         * reflection.c: update the parameter table index.
7244
7245 Sat Jul 13 17:34:23 CEST 2002 Paolo Molaro <lupus@ximian.com>
7246
7247         * domain.c: don't include the mark byte in the string hash.
7248
7249 Sat Jul 13 15:06:23 CEST 2002 Paolo Molaro <lupus@ximian.com>
7250
7251         * icall.cs: icall for Type.GetTypeCode ().
7252         * verify: a couple of fixes and disabled local initialization checks.
7253
7254 2002-07-12  Dietmar Maurer  <dietmar@ximian.com>
7255
7256         * marshal.c: better debugging support (DEBUG_RUNTIME_CODE)
7257
7258         * debug-helpers.c (mono_method_full_name): print the type of the
7259         runtime wrapper
7260
7261         * metadata.c (mono_signature_hash): a hash function for signatures
7262         (mono_signature_hash): better hash algorithm
7263
7264         * marshal.c (mono_marshal_get_delegate_invoke): cache methods by signature
7265
7266         * debug-helpers.c (mono_method_full_name): this can now generate
7267         method names with signatures
7268
7269         * marshal.c (mono_marshal_get_managed_wrapper): bug fix: unmanaged
7270         method dont have this pointers.
7271
7272 Fri Jul 12 11:35:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
7273
7274         * reflection.c: fixup typebuilder tokens.
7275         * image.c: fix buglet.
7276         * marshal.h: remove whitespace.
7277         * metadata.h, metadata.c: reinstate code that was removed.
7278         * verify.c: handle catch directives and fix another couple of bugs.
7279
7280 2002-07-11  Dietmar Maurer  <dietmar@ximian.com>
7281
7282         * marshal.c (mono_marshal_get_native_wrapper): support BOOLEAN
7283         (mono_marshal_get_native_wrapper): make it comp. with the old code
7284         (mono_marshal_get_native_wrapper): support boolean
7285         (mono_marshal_get_managed_wrapper): support more types
7286
7287 2002-06-25  Dietmar Maurer  <dietmar@ximian.com>
7288
7289         * class.c (class_compute_field_layout): compute class->blittable attribute.
7290
7291 2002-07-09  Dick Porter  <dick@ximian.com>
7292
7293         * threads.c: Make the thread cleaning up cope with threads that
7294         call ExitThread()
7295
7296 2002-07-08  Radek Doulik  <rodo@ximian.com>
7297
7298         * reflection.c (method_encode_code): use non-translated values to
7299         compute finally_start, this fixes exception handling on ppc, yay!
7300
7301         * decimal.h (struct signscale): fix endianess
7302
7303 2002-07-07  Radek Doulik  <rodo@ximian.com>
7304
7305         * reflection.c: swap box_val and not val
7306
7307 Mon Jul 8 15:18:59 CEST 2002 Paolo Molaro <lupus@ximian.com>
7308
7309         * reflection.c, reflection.h: handle full assembly info in type name.
7310         Handle Type arguments when loading custom attributes.
7311         * icall.c: updated to use new mono_reflection_type_from_name () method.
7312
7313 2002-07-07  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7314
7315         * loader.c:
7316         (method_from_memberref): also print assembly name when method not found.
7317
7318 2002-07-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7319
7320         * icall.c:
7321         (ves_icall_TypeGetProperties): fixed bug #27473. 
7322
7323 2002-07-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7324
7325         * reflection.c: display image name and token when cannot find the
7326         .ctor for an attribute.
7327
7328 2002-07-05  Martin Baulig  <martin@gnome.org>
7329
7330         * debug-symfile.c: Reflect latest MonoDwarfFileWriter changes.
7331
7332 2002-07-04  Dick Porter  <dick@ximian.com>
7333
7334         * threads.c (mono_thread_cleanup): Nasty kludge to get this to
7335         compile on mingw.  This will cause mingw builds to not wait for
7336         subthreads to terminate after the main thread does.  I've lodged a
7337         bug with the mingw developers for them to wrap OpenThread().
7338
7339 2002-07-03  Dick Porter  <dick@ximian.com>
7340
7341         * threads.c: Store thread IDs instead of handles, because
7342         GetCurrentThread() returns a pseudohandle and therefore stores
7343         useless values.  mono_thread_cleanup() continues checking the
7344         array of threads until it is empty, to cope with subthreads
7345         spawning new threads after the main thread has finished.
7346
7347         * profiler.h:
7348         * profiler.c:
7349         * profiler-private.h: Pass the thread ID to thread profiler
7350         functions, instead of a handle
7351
7352 Wed Jul 3 17:43:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
7353
7354         * verify.c: fixes to make it more usable.
7355         * pedump.c: added --verify code to verify IL code in an assembly.
7356
7357 Tue Jul 2 20:40:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
7358
7359         * reflection.c: turn errors into warnings to allow compiling corlib.
7360
7361 Tue Jul 2 19:33:20 CEST 2002 Paolo Molaro <lupus@ximian.com>
7362
7363         * reflection.c: add special cases to compile corlib.
7364
7365 Mon Jul 1 18:00:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
7366
7367         * reflection.c: handle properties with only a set method.
7368
7369 Mon Jul 1 17:11:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
7370
7371         * opcodes.h: add enum with opcodes in opval order.
7372
7373 2002-07-01  Dick Porter  <dick@ximian.com>
7374         
7375         * object.h:
7376         * object.c (mono_runtime_run_main): Removed unneeded argument
7377
7378 2002-06-28  Martin Baulig  <martin@gnome.org>
7379
7380         * debug-symfile.c: Reflect latest MonoDwarfFileWriter changes.
7381
7382 2002-06-27  Dick Porter  <dick@ximian.com>
7383
7384         * threads.c: Store the handle in both the parent thread and in the
7385         subthread, to minimise the time between starting a new thread and
7386         storing its ID.
7387
7388 2002-06-26  Dick Porter  <dick@ximian.com>
7389
7390         * appdomain.c (mono_runtime_cleanup): Close the socket library
7391         after all the threads have finished, not before
7392
7393 2002-06-26  Martin Baulig  <martin@gnome.org>
7394
7395         * debug-symfile.c (mono_debug_find_source_location): Added
7396         `guint32 *line_number' argument.  If it's not NULL, store the line number
7397         there and return the file name without the line number.
7398
7399 2002-06-25  Dick Porter  <dick@ximian.com>
7400
7401         * icall.c:
7402         * process.h:
7403         * process.c: Process forking and other support functions
7404
7405 2002-06-25  Dick Porter  <dick@ximian.com>
7406
7407         * image.c (do_mono_image_open): Set ref_count to 1, so that bad
7408         things dont happen when the image is closed.
7409         (mono_image_lookup_resource): Walk the resource section looking
7410         for a particular entry
7411
7412         * cil-coff.h: PE resource section decoding
7413
7414 2002-06-25  Dick Porter  <dick@ximian.com>
7415         
7416         * assembly.h:
7417         * assembly.c: 
7418         (mono_assembly_foreach): Accessor functions to walk the list of
7419         loaded assemblies
7420         (mono_assembly_set_main):
7421         (mono_assembly_get_main): Process methods need to know which
7422         assembly is the "main" one
7423
7424         * object.c (mono_runtime_run_main): Record the main assembly
7425
7426         * debug-helpers.c: Fix typo
7427
7428 2002-06-24  Dietmar Maurer  <dietmar@ximian.com>
7429
7430         * icall.c (ves_icall_System_Runtime_InteropServices_Marshal_copy_to_unmanaged): impl.
7431         (ves_icall_System_Runtime_InteropServices_Marshal_copy_from_unmanaged): impl.
7432
7433 Sat Jun 22 11:37:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
7434
7435         * icall.c: fix off-by-one in Assembly.GetTypes() reported by bob@karr.ath.cx.
7436
7437 2002-06-21  Miguel de Icaza  <miguel@ximian.com>
7438
7439         * image.c (do_mono_image_open): Initialize reference count,
7440         otherwise we leak the MonoImage.
7441
7442 Fri Jun 21 19:16:47 CEST 2002 Paolo Molaro <lupus@ximian.com>
7443
7444         * reflection.c: small tweak to handle self-hosting.
7445
7446 Thu Jun 20 23:28:13 CEST 2002 Paolo Molaro <lupus@ximian.com>
7447
7448         * reflection.c: fix type name parse code.
7449
7450 Thu Jun 20 19:24:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
7451
7452         * reflection.c: break out of the loop.
7453         * image.c: special case corlib.
7454
7455 Thu Jun 20 16:43:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
7456
7457         * reflection.c: add all the custom attrs at the end to ensure the
7458         ctors have been properly initialized when the attributes are defined
7459         in the current assembly.
7460
7461 Thu Jun 20 13:46:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
7462
7463         * reflection.c: handle correctly multiple-nested types.
7464
7465 Thu Jun 20 11:49:00 CEST 2002 Paolo Molaro <lupus@ximian.com>
7466
7467         * row-indexes.h: fix typos.
7468         * reflection.c: adjust for typos and fix method_def_or_ref
7469         encoding in MethodImpl table.
7470
7471 Wed Jun 19 21:57:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
7472
7473         * reflection.c: fix entry point patching (thanks Serge!).
7474
7475 2002-06-18  Dietmar Maurer  <dietmar@ximian.com>
7476
7477         * verify.c: add check for System.Exception
7478
7479 Mon Jun 17 20:23:23 CEST 2002 Paolo Molaro <lupus@ximian.com>
7480
7481         * image.c, class.c: minifix for code just c&p'ed.
7482         * reflection.c: warning fix.
7483         * object.h, loader.h, domain.c: load also StringBuilder.
7484
7485 Mon Jun 17 17:29:40 CEST 2002 Paolo Molaro <lupus@ximian.com>
7486
7487         * marshal.h, marshal.c: some support code to handle complex marshaling.
7488
7489 Mon Jun 17 16:32:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
7490
7491         * class.h, class.c, reflection.c: handle ignorecase in GetType ().
7492         Better signatures with vtable error dump.
7493
7494 Mon Jun 17 16:13:35 CEST 2002 Paolo Molaro <lupus@ximian.com>
7495
7496         * reflection.c, reflection.h, icall.c: fixes for multiple-nested types.
7497
7498 2002-06-17  Dietmar Maurer  <dietmar@ximian.com>
7499
7500         * icall.c (ves_icall_Type_GetField): impl.
7501
7502 Mon Jun 17 16:08:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
7503
7504         * metadata.h, metadata.c: added mono_metadata_get_marshal_info()
7505         to retrieve a marshal description blob for a field or param.
7506
7507 Mon Jun 17 14:57:03 CEST 2002 Paolo Molaro <lupus@ximian.com>
7508
7509         * reflection.h, reflection.c: change order of nested type emission
7510         to avoid table corruption. The NestedTypes table is sorted.
7511         * icall.c: change order of GetConstructor results to workaround mcs bug.
7512
7513 Fri Jun 14 16:24:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
7514
7515         * reflection.h, reflection.c: handle field and param marshal
7516         information.
7517
7518 Wed Jun 12 16:30:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
7519
7520         * icall.c, marshal.c marshal.h: more Marshal class implementation.
7521
7522 Tue Jun 11 17:29:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
7523
7524         * reflection.c: fix call convention.
7525
7526 Tue Jun 11 16:52:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
7527
7528         * reflection.h, reflection.c: mono_image_get_memberref_token()
7529         takes a type instead of a class, now. Added
7530         mono_image_get_array_token() to create tokens for the special
7531         multi-dim array methods.
7532
7533 Tue Jun 11 13:21:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
7534
7535         * assembly.c: handle modules (no assembly table). Split
7536         loading references in its own function.
7537         * class.c: handle moduleref resolution scope.
7538         * image.c, image.h: cache module name in image.
7539
7540 2002-06-07  Martin Baulig  <martin@gnome.org>
7541
7542         * reflection.c (mono_image_get_type_info): Only add a class layout entry
7543         if we actually have a `tb->class_size' (ie. it's not UnspecifiedTypeSize).
7544
7545 Fri Jun 7 22:07:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
7546
7547         * icall.c: more signature fixes that used uint instead of int.
7548
7549 Fri Jun 7 20:41:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
7550
7551         * reflection.c: fixed signature of field refs.
7552
7553 Fri Jun 7 19:41:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
7554
7555         * class.c, reflection.c: handle typerefs of nested types
7556         (both on read and when writing files).
7557
7558 Fri Jun 7 17:46:50 CEST 2002 Paolo Molaro <lupus@ximian.com>
7559
7560         * icall.c: fix method signatures that tried to workaround the previous
7561         typo, d'oh!
7562
7563 Fri Jun 7 17:36:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
7564
7565         * debug-helpers.c: fix typo.
7566
7567 Fri Jun 7 17:00:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
7568
7569         * cil-coff.h, icall.c, image.c, reflection.c, reflection.h:
7570         rewrote the PE/COFF writing code (our programs are understood by the
7571         ms runtime, now).
7572
7573 Tue Jun 4 18:10:47 CEST 2002 Paolo Molaro <lupus@ximian.com>
7574
7575         * gc.c, gc.h, icall.c: weakreference support.
7576
7577 Tue Jun 4 16:06:19 CEST 2002 Paolo Molaro <lupus@ximian.com>
7578
7579         * Makefile.am, mono-config.c: use $(sysconfdir).
7580
7581 Mon Jun 3 13:13:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
7582
7583         * icall.c: changed default precision of Double.ToString() to 15.
7584         Fixed memory leak. Unified with Single.ToString.
7585
7586 Sat Jun 1 14:26:45 CEST 2002 Paolo Molaro <lupus@ximian.com>
7587
7588         * sysmath.c: workaround systems missing NAN and/or HUGE_VAL.
7589
7590 Sat Jun 1 13:46:54 CEST 2002 Paolo Molaro <lupus@ximian.com>
7591
7592         * pedump.c, appdomain.c, appdomain.h, assembly.c, domain.c,
7593         gc.c, icall.c, image.c, mono-config.c, reflection.c: killed
7594         warnings and compilation fixes from Dennis Haney (davh@davh.dk)
7595         and myself.
7596
7597 Fri May 31 16:58:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
7598
7599         * debug-symfile.c, sysmath.c: yet more compilation fixes.
7600
7601 Fri May 31 16:35:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
7602
7603         * reflection.c, socket-io.c: more compilation fixes.
7604
7605 Fri May 31 15:58:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
7606
7607         * appdomain.c, class.c, class.h, debug-symfile.c, decimal.c,
7608         domain.c, loader.c, object.c, object.h, reflection.c, string-icalls.h,
7609         unicode.c: warning and compiler compatibility fixes.
7610
7611 Fri May 31 15:36:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
7612
7613         * class.h, metadata.c: fixed warnings/compilation errors.
7614
7615 Fri May 31 13:08:25 CEST 2002 Paolo Molaro <lupus@ximian.com>
7616
7617         * Makefile.am, mono-config.c, mono-config.h: configuration file
7618         support routines.
7619         * loader.c, loader.h: make Dll mapping configurable at runtime in the
7620         config file. Export methods to insert and lookup mappings.
7621
7622 Fri May 31 12:45:38 CEST 2002 Paolo Molaro <lupus@ximian.com>
7623
7624         * reflection.c: handle types and boxed objects in custom attr
7625         constructors.
7626
7627 2002-05-30  Martin Baulig  <martin@gnome.org>
7628
7629         * debug-symfile.c
7630         (ves_icall_Debugger_MonoSymbolWriter_method_builder_from_token): Removed.
7631
7632 Thu May 30 14:15:02 CEST 2002 Paolo Molaro <lupus@ximian.com>
7633
7634         * metadata.c, metadata.h: added mono_metadata_implmap_from_method()
7635         to lookup the implmap row for a P/Invoke method.
7636         * loader.c: added mono_lookup_pinvoke_call(): we only lookup a
7637         P/Invoke method from the runtime on an as needed basis.
7638
7639 2002-05-28  Dietmar Maurer  <dietmar@ximian.com>
7640
7641         * metadata.c (mono_metadata_parse_signature): impl.
7642
7643 Tue May 28 16:02:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
7644
7645         * class.c: handle .pack directive.
7646
7647 Tue May 28 11:04:46 CEST 2002 Paolo Molaro <lupus@ximian.com>
7648
7649         * object.c: initialize static fields with RVA data.
7650
7651 2002-05-25  Martin Baulig  <martin@gnome.org>
7652
7653         * debug-symfile.c
7654         (ves_icall_Debugger_DwarfFileWriter_get_type_token): Removed.
7655
7656 2002-05-24  Martin Baulig  <martin@gnome.org>
7657
7658         * debug-symfile.c
7659         (ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig): Removed.
7660         (ves_icall_Debugger_MonoSymbolWriter_method_from_token): Renamed to
7661         `ves_icall_Debugger_MonoSymbolWriter_method_builder_from_token'.
7662
7663 Thu May 23 18:44:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
7664
7665         * object.c: special case string ctros in invoke.
7666         * gc.c: silly whitespace changes.
7667
7668 2002-05-23  Dietmar Maurer  <dietmar@ximian.com>
7669
7670         * threadpool.[ch]: impl. a threadpool that can
7671         be used by mint and mono.
7672
7673 2002-05-22  Martin Baulig  <martin@gnome.org>
7674
7675         * debug-symfile.c (ves_icall_Debugger_MonoSymbolWriter_method_from_token):
7676         The first argument is now a `MonoReflectionModuleBuilder *', the return
7677         value is a `MonoReflectionModuleBuilder *'.  Use the AssemblyBuilder's
7678         `methods' field to get the method builder.  The `token' argument is the
7679         unfixed token.
7680
7681         * unicode.c (iconv_get_length, iconv_convert): Silently ignore all
7682         invalid characters instead of g_assert_not_reached()ing.  This seems
7683         to be the behaviour of mscorlib.
7684
7685 2002-05-22  Dietmar Maurer  <dietmar@ximian.com>
7686
7687         * object.c (mono_runtime_invoke_array): applied patch from Rachel
7688         Hestilow to fix bug #25104
7689
7690 2002-05-21  Martin Baulig  <martin@gnome.org>
7691
7692         * debug-symfile.c (mono_debug_find_source_location): New function.
7693         Looks up an IL offset in the line number table and returns the source
7694         location as a string.
7695
7696 2002-05-21  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7697
7698         * icall.c:
7699         (mono_double_ToStringImpl): changed %f by %g until we have something
7700         better.
7701
7702 2002-05-21  Nick Drochak  <ndrochak@gol.com>
7703
7704         * icall.c : Use different name for Math.Pow's icall.  Needed to check
7705         parameters first in C#.
7706
7707 Mon May 20 17:36:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
7708
7709         * icall.c, reflection.h: added icall to get info about an event.
7710
7711 2002-05-20  Radek Doulik  <rodo@ximian.com>
7712
7713         * object.c (mono_value_box): don't use memcpy for boxing on BIG
7714         endian
7715         (mono_value_box): don't use memcpy for small sizes on
7716         architectures with unaligned access
7717
7718 2002-05-20  Martin Baulig  <martin@gnome.org>
7719
7720         * reflection.c (mono_reflection_setup_internal_class): Don't crash
7721         if `tb->parent == NULL'.
7722         (mono_reflection_create_internal_class): New function.  This is
7723         called from TypeBuilder.CreateType() and sets `klass->enum_basetype'
7724         for enum types.
7725
7726         * icall.c ("System.Reflection.Emit.TypeBuilder::create_internal_class"):
7727         New interncall.
7728
7729 2002-05-19  Martin Baulig  <martin@gnome.org>
7730
7731         * unicode.c (ves_icall_iconv_get_bytes): Actually use the `charCount'
7732         argument to get the length, don't default to the array length.
7733
7734 2002-05-18  Miguel de Icaza  <miguel@ximian.com>
7735
7736         * assembly.c (mono_assembly_setrootdir): New function used to
7737         override the MONO_ASSEMBLIES directory.
7738
7739 Fri May 17 20:39:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
7740
7741         * icall.c: ValueType_GetHashCode() initialize local var.
7742
7743 Thu May 16 17:20:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
7744
7745         * reflection.c: sort custom attributes table.
7746
7747 Thu May 16 16:08:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
7748
7749         * reflection.c: support named args in custom attributes (write support).
7750
7751 Thu May 16 13:04:59 CEST 2002 Paolo Molaro <lupus@ximian.com>
7752
7753         * reflection.c: fix finally position calculation.
7754
7755 2002-05-15  Radek Doulik  <rodo@ximian.com>
7756
7757         * reflection.c: fixed endianess at many places
7758
7759         * icall.c (ves_icall_InitializeArray): comment out debug msg
7760
7761 2002-05-15  Dietmar Maurer  <dietmar@ximian.com>
7762
7763         * object.c (mono_unhandled_exception): new function to handle
7764         unhandled exceptions.
7765         (mono_unhandled_exception): call the UnhandledException event.
7766         (mono_runtime_delegate_invoke): impl.
7767
7768 Wed May 15 15:59:55 CEST 2002 Paolo Molaro <lupus@ximian.com>
7769
7770         * metadata.h, metadata.c, class.c: mono_metadata_field_info ()
7771         returns the RVA, not the direct pointer to the data. Handle the case
7772         when the class size is fixed.
7773
7774 Tue May 14 16:59:44 CEST 2002 Paolo Molaro <lupus@ximian.com>
7775
7776         * reflection.c: fix some endianess issues.
7777
7778 2002-05-14  Dietmar Maurer  <dietmar@ximian.com>
7779
7780         * object.c (mono_runtime_invoke): is now able to catch exceptions.
7781
7782         * threads.c (mono_thread_init): added a callback which is invoked
7783         at thread start.
7784
7785 2002-05-14  Dan Lewis  <dihlewis@yahoo.co.uk>
7786         
7787         * icall.c: make GetHashCode return non-negative values.
7788
7789 2002-05-14  Dan Lewis  <dihlewis@yahoo.co.uk>
7790
7791         * object.c, icall.c, gc.c: revert to address-based hashcode.
7792
7793 2002-05-13  Miguel de Icaza  <miguel@ximian.com>
7794
7795         * icall.c (mono_double_ParseImpl): Added ParseImpl method.
7796
7797 Mon May 13 16:40:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
7798
7799         * icall.c, class.c: special case <Module>.
7800
7801 2002-05-13  Dan Lewis  <dihlewis@yahoo.co.uk>
7802
7803         * icall.c: fix bug in GetNow().
7804
7805 2002-05-11  Dietmar Maurer  <dietmar@ximian.com>
7806
7807         * object.c (mono_runtime_class_init): make sure that we call all
7808         static class constructors.
7809
7810 Fri May 10 18:14:51 CEST 2002 Paolo Molaro <lupus@ximian.com>
7811
7812         * reflection.c: sort methodsemantics table.
7813
7814 Fri May 10 16:31:49 CEST 2002 Paolo Molaro <lupus@ximian.com>
7815
7816         * reflection.h, reflection.c: honour init locals setting.
7817
7818 Thu May 9 18:50:00 EDT 2002 Daniel Morgan <danmorg@sc.rr.com>
7819
7820         * icall.c: copied Double ToStringImpl for Single ToStringImpl
7821
7822 Wed May 8 12:28:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
7823
7824         * reflection.c: support ContructorBuilders in attribute blob creation.
7825
7826 Wed May 8 12:06:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
7827
7828         * reflection.c: some changes to build a binary that can be run
7829         directly in windows.
7830
7831 Mon May 6 13:10:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
7832
7833         * loader.c: print a big message when an icall can't be found.
7834
7835 2002-05-06  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7836
7837         * string-icalls.c: fix bug 24248.
7838
7839 Sat May 4 14:03:21 CEST 2002 Paolo Molaro <lupus@ximian.com>
7840
7841         * appdomain.c, appdomain.h, assembly.c, assembly.h, image.h,
7842         icall.c, reflection.h: separate assembly loading by pathname and by
7843         assembly name. Use the MONO_PATH env var to search for assemblies.
7844
7845 Thu May 2 17:56:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
7846
7847         * assembly.c, image.h: add some support for assemblies
7848         with multiple modules.
7849         * class.c, class.h: export mono_class_from_typeref().
7850         * loader.c: remove duplicated code and use mono_class_from_typeref(),
7851         instead.
7852
7853 Thu May 2 15:51:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
7854
7855         * unicode.c: Char.IsNumber doesn't include hex digits as the ms
7856         documentation says (the ECMA one is correct).
7857
7858 2002-05-02  Dick Porter  <dick@ximian.com>
7859
7860         * threads.c: Use GC_debug_register_finalizer with GC_debug_malloc.
7861         Don't name the synchronisation mutex.
7862
7863 2002-04-30  Jeffrey Stedfast  <fejj@ximian.com>
7864
7865         * rand.c
7866         (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetBytes):
7867         Make the prototypes match.
7868         (ves_icall_System_Security_Cryptography_RNGCryptoServiceProvider_GetNonZeroBytes):
7869         Same.
7870
7871         * icall.c
7872         (ves_icall_System_CurrentTimeZone_GetTimeZoneData): Fixed for
7873         systems that use 'timezone' rather than tm.tm_gmtoff. Also, not
7874         all systems have tm.tm_zone, so use strftime() with %Z to print
7875         the timezone abreviation into a temp string.
7876
7877         * object.c (mono_ldstr): Fixed to use mono_string_chars() macro
7878         rather than mono_array_addr() on a MonoString on Big Endian
7879         machines.
7880
7881 2002-04-30  Dietmar Maurer  <dietmar@ximian.com>
7882
7883         * string-icalls.c (ves_icall_System_String_InternalReplace_Str):
7884         fix bug 24041
7885
7886 2002-04-30  Dick Porter  <dick@ximian.com>
7887
7888         * socket-io.c: Cope with SOCKET being an integer rather than a
7889         pointer now.
7890
7891         * threads.c: Added Thread_free_internal, to deal with thread
7892         handle cleanup.  Moved calls to handle_store() and handle_remove()
7893         to start_wrapper(), so each can only be called once.  Allocate
7894         synchronisation blocks with GC_malloc(), and use GC finalisation
7895         to close the handles.
7896
7897         * icall.c: added System.Threading.Thread::Thread_free_internal
7898
7899 Mon Apr 29 15:33:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
7900
7901         * icall.c: support Environment.Exit, CommandLineArgs().
7902
7903 Mon Apr 29 15:15:57 CEST 2002 Paolo Molaro <lupus@ximian.com>
7904
7905         * object.c, object.h: added mono_runtime_run_main () and
7906         mono_runtime_get_main_args () for use in System.Environment.
7907
7908 Mon Apr 29 13:45:11 CEST 2002 Paolo Molaro <lupus@ximian.com>
7909
7910         * gc.c: fix thinko, enable actual finalization since the jit is now
7911         fixed.
7912
7913 Mon Apr 29 12:47:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
7914
7915         * gc.c, object.c: take into account that an object may be offset wrt the address
7916         returned by GC_malloc().
7917
7918 Mon Apr 29 12:14:39 CEST 2002 Paolo Molaro <lupus@ximian.com>
7919
7920         * image.c: handle files without entries in the assembly table (modules).
7921
7922 2002-04-28 Patrik Torstensson <patrik.torstensson@intel.com>
7923
7924         * reflection.c (mono_reflection_setup_internal_class): remove g_assert_not_reached() to allow 
7925         mcs selfhosting again (build breaker) and did move the check to class instead. parent is
7926         allowed to be null when it's System.Object class setup.
7927
7928 2002-04-27  Martin Baulig  <martin@gnome.org>
7929
7930         * reflection.c (mono_reflection_setup_internal_class): g_assert_not_reached()
7931         if `tb->parent == NULL' rather than crashing.
7932
7933 2002-04-28  Nick Drochak  <ndrochak@gol.com>
7934
7935         * sysmath.c (ves_icall_System_Math_Asin): Fix copy-paste error.  Was
7936         calling acos() where asin() should have been called.
7937
7938 2002-04-26  Martin Baulig  <martin@gnome.org>
7939
7940         * assembly.c (default_assembly_name_resolver): Use G_FILE_TEST_IS_REGULAR
7941         instead of G_FILE_TEST_EXISTS - if you're in mcs/class/corlib/System/Test,
7942         there's a subdirectory called `System', but we don't want to read that
7943         subdirectory as an assembly.
7944
7945 2002-04-25  Martin Baulig  <martin@gnome.org>
7946
7947         * debug-symfile.c: Reflect latest MonoString changes.
7948
7949 Thu Apr 25 16:38:01 CEST 2002 Paolo Molaro <lupus@ximian.com>
7950
7951         * rand.c, rand.h: instance method icalls need to have an explicit
7952         this pointer as first argument in the C implementation.
7953
7954 2002-04-25  Nick Drochak <ndrochak@gol.com>
7955
7956         * icall.c: Fix typo in map for GetNonZeroBytes
7957
7958 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
7959
7960         * string-icalls.c : String does now passes unit tests without any 
7961         errors, the following changes has been made:
7962         
7963         Implemented replace methods.
7964         Renaming of methods to (try) follow the standard.
7965         Fixed compare ordinal
7966         Made all memory allocated directly to function instead of via icall function.
7967         Small performance fix in is_in_array function
7968                         
7969  (2002-04-23) Changes from Duncan Mak <duncan@ximian.com>
7970
7971         c (mono_string_Internal_ctor_charp_int_int):
7972         (mono_string_Internal_ctor_sbytep_int_int):  Removed check for
7973         sindex < 0, throw ArgumentOutOfRangeException instead of
7974         ArgumentNullException.
7975
7976         Added new check for length == 0, however
7977         I need to make it return String.Empty from the C code.
7978         
7979         (mono_string_Internal_ctor_sbytep): Use mono_string_new, and let
7980         that calculate the length for us here.
7981         
7982         (mono_string_Internal_ctor_sbytep_int_int): Replaced
7983         mono_string_new_utf16 with mono_string_new, since value is utf8.
7984
7985 Wed Apr 24 18:43:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
7986
7987         * object.c: register the object for finalization if needed.
7988         Allocate one more char in the string for the terminating 0 char.
7989
7990 Wed Apr 24 18:22:27 CEST 2002 Paolo Molaro <lupus@ximian.com>
7991
7992         * class.c, class.h, image.c: check if a type implemenst a destructor.
7993         Use the proper key for array class lookups.
7994         * icall.c: register the icalls in the System.GC class.
7995         * gc.c, gc.h: GC-related functions and icalls.
7996
7997 2002-04-24  Gonzalo Paniagua Javier <gonzalo@ximian.com>
7998
7999         * icall.c:
8000         * socket-io.c:
8001         * unicode.c: free some strings gotten from mono_string_to_utf8 and
8002         changed a couple of free () by g_free ().
8003
8004         * decimal.c: one-liner in the comments for decimal2string ().
8005
8006 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
8007
8008         * object.c (mono_runtime_invoke_array) : Bug because of my incompetence.
8009
8010 2002-04-24      Patrik Torstensson <patrik.torstensson@labs2.com>
8011
8012         * reflection.c (mono_reflection_get_custom_attrs) : fixed image bug (crash)
8013         * object.c (mono_runtime_invoke_array) : handle null in params
8014
8015 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
8016
8017         * string-icalls.c: fixed bug in split (one off bug)
8018
8019 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
8020
8021         * string-icalls.c: fixed bug in remove and lastindexofany, add equals icall.
8022         * icalls.c: added String::Equals as internal method
8023
8024 2002-04-23      Patrik Torstensson <patrik.torstensson@labs2.com>
8025
8026         * threads.c: fixed bug in the double interlocked functions
8027
8028 2002-04-22      Patrik Torstensson <patrik.torstensson@labs2.com>
8029
8030         * threads.c: implemented all of the new interlocked icalls.
8031         * string-icalls.c: fix a bug in insert.
8032         * icalls.c: added the icalls for interlocked, removed old string functions.
8033         
8034 Mon Apr 22 19:44:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
8035
8036         * loader.c: fix off-by-one error when reading argument names.
8037
8038 Mon Apr 22 19:28:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
8039
8040         * profiler.c: win32 counter implementation (untested).
8041         * icall.cs: win32 GetNow() and GetTimeZoneData() implementations
8042         (the latter needs testing and more complete impl. from win32 folks).
8043
8044 2002-04-21  Dan Lewis  <dihlewis@yahoo.co.uk>
8045
8046         * object.c: mono_array_new_full workaround mono_array_class_get
8047         problem.
8048
8049 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
8050
8051         * string-icalls.c (mono_string_InternalRemove): Fixed overwrite bug.
8052         * object.h (mono_string_chars): Changed casting type.
8053
8054 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
8055
8056         * string-icalls.c: Fixed trim method, added the constructors done by Duncan, fixed
8057                            method signatures to use gunichar2 instead of gint16.
8058
8059 2002-04-20  Dan Lewis  <dihlewis@yahoo.co.uk>
8060
8061         * object.h, object.c: domain-specific versions of mono_object_new and
8062         mono_array_new.
8063
8064 2002-04-20  Dietmar Maurer  <dietmar@ximian.com>
8065
8066         * object.c: changed String layout
8067
8068         * string-icalls.c (mono_string_Internal_ctor_chara): added
8069         internal string constructors.
8070
8071 Sat Apr 20 13:33:07 CEST 2002 Paolo Molaro <lupus@ximian.com>
8072
8073         * threads.c: pass 'this' to the thread start routine.
8074
8075 2002-04-20  Gonzalo Paniagua Javier <gonzalo@ximian.com>
8076
8077         * string-icalls.c: fix IndexOf and LastIndexOf. Now
8078         InternalCompareStr don't call twice mono_string_cmp_char for the last
8079         character. Improved performance in mono_string_cmp_char.
8080
8081 Fri Apr 19 19:26:28 CEST 2002 Paolo Molaro <lupus@ximian.com>
8082
8083         * Makefile.am, appdomain.c, class.c, object.c: split runtime-depended
8084         code into its own library: libmonoruntime.
8085
8086 2002-04-19  Dan Lewis  <dihlewis@yahoo.co.uk>
8087
8088         * object.h, object.c: changed array format so that szarrays do not
8089         require a bounds structure.
8090         * icall.c, appdomain.c: support for new szarray format.
8091
8092 Fri Apr 19 18:04:34 CEST 2002 Paolo Molaro <lupus@ximian.com>
8093
8094         * metadata.c: compare also the retuns type when comparing signatures:
8095         we didn't do this as an optimization since really overloaded methods
8096         must differ also in the arguments, but this doesn't work with
8097         low-level IL code (or when using explicit conversion operators: see
8098         bug#23498 for an example).
8099
8100 Fri Apr 19 16:14:52 CEST 2002 Paolo Molaro <lupus@ximian.com>
8101
8102         * loader.c: SZARRAY types can be saved as TYPESPEC, too.
8103
8104 Thu Apr 18 17:15:09 CEST 2002 Paolo Molaro <lupus@ximian.com>
8105
8106         * icall.c: make MonoType::GetElementType its own icall.
8107
8108 Thu Apr 18 16:41:30 CEST 2002 Paolo Molaro <lupus@ximian.com>
8109
8110         * icall.c: remove MonoMethod_get_Name().
8111         * reflection.c, reflection.h, verify: cache the method name in the MonoMethod
8112         object.
8113
8114 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
8115
8116         * string-icalls.c: optimized a few methods.
8117
8118 2002-04-17      Patrik Torstensson <patrik.torstensson@labs2.com>
8119
8120         * icall.c: added all new string internal calls
8121         * string-icalls.c: added, new string internal call implementation.
8122         * object.c: added mono_string_new_size for allocating a string a size
8123
8124 2002-04-17  Dietmar Maurer  <dietmar@ximian.com>
8125
8126         * object.c (mono_object_isinst): use the same code as in the
8127         optimized x86 version.
8128
8129 Wed Apr 17 14:14:36 CEST 2002 Paolo Molaro <lupus@ximian.com>
8130
8131         * profiler.c: TSC-based timer code (faster and more accurate).
8132         Not hooked up in configure, yet (set USE_X86TSC to 1).
8133
8134 Wed Apr 17 12:33:10 CEST 2002 Paolo Molaro <lupus@ximian.com>
8135
8136         * profiler.c, profiler.h: track time spent compiling methods.
8137         * threads.c: track thread creation/destruction.
8138
8139 Tue Apr 16 20:08:43 CEST 2002 Paolo Molaro <lupus@ximian.com>
8140
8141         * profiler.c, profiler.h, profiler-private.h: profiling interface
8142         and sample implementation. Moved here so that it can be used also by
8143         the jit.
8144
8145 Tue Apr 16 12:58:12 CEST 2002 Paolo Molaro <lupus@ximian.com>
8146
8147         * reflection.c, reflection.h: keep types and other handles separate in
8148         the hash tables for referred tokens. Add guid for modules.
8149
8150 Mon Apr 15 11:37:33 CEST 2002 Paolo Molaro <lupus@ximian.com>
8151
8152         * assembly.c: fix bugs found with valgrind.
8153         * metadata.h, metadata.c: added mono_metadata_guid_heap().
8154
8155 2002-04-14      Patrik Torstensson <patrik.torstensson@labs2.com>
8156
8157         * threads: added icall support for getting current domain for
8158                    the thread.
8159  
8160 2002-04-13  Martin Baulig  <martin@gnome.org>
8161
8162         * debug-symfile.h (MonoDebugLocalInfo): Renamed to MonoDebugVarInfo.
8163         (MonoDebugVarInfo): Added `index' field for register based addresses.
8164         (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 9.
8165         (MonoDebugMethodInfo): Replaced `guint32 *param_offsets' with
8166         `MonoDebugVarInfo *params' and `guint32 this_offset' with
8167         `MonoDebugVarInfo *this_var'.
8168
8169         * debug-symfile.c (relocate_variable): New static function to write
8170         a location description for a local variable or method parameter.
8171
8172 2002-04-12  Martin Baulig  <martin@gnome.org>
8173
8174         * debug-symfile.h (MonoDebugLocalInfo): New type. This contains the
8175         stack offset and begin/end scope address of a local variable.
8176         (MonoDebugMethodInfo): Replaced `guint32 *local_offsets' with
8177         'MonoDebugLocalInfo *locals', added `prologue_end' and `epilogue_begin'.
8178         (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 8.
8179
8180         * debug-symfile.c (MRT_variable_start_scope, MRT_variable_end_scope):
8181         Added new relocation types for start/end scope of a local variable.
8182
8183 Fri Apr 12 18:30:29 CEST 2002 Paolo Molaro <lupus@ximian.com>
8184
8185         * object.h: add mono_object_domain() macro.
8186         * reflection.c: handle typespecs.
8187         * icall.c: MonoMethod::get_Name() implementation.
8188
8189 Thu Apr 11 12:29Ni:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
8190
8191         * icall.c: String::GetHashCode() icall implementation.
8192
8193 Wed Apr 10 21:16:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
8194
8195         * icall.c: String::IndexOfAny icall.
8196         * object.c, object.h: make array->max_length more useful.
8197         Intrduced mono_object_class() and mono_string_length() macros.
8198
8199 2002-04-10  Gonzalo Paniagua Javier <gonzalo@ximian.com>
8200
8201         * unicode.c (ves_icall_System_Char_IsNumber): use g_unichar_isxdigit
8202         instead of g_unichar_isdigit.
8203
8204 2002-04-11  Nick Drochak  <ndrochak@gol.com>
8205
8206         * icall.c: Implement a simple Double.ToString().
8207
8208 Tue Apr 9 21:31:16 CEST 2002 Paolo Molaro <lupus@ximian.com>
8209
8210         * appdomain.h: only io-layer.h is supposed to be included.
8211         * icall.c: explicitly import environ. Fix warning.
8212
8213 2002-04-10  Nick Drochak  <ndrochak@gol.com>
8214
8215         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData) :
8216                 return true even if it's not Daylight Savings time.
8217                 Only return false for the case where the function isn't
8218                 implemented for a plaform (read Windows).
8219
8220 Tue Apr 9 13:05:56 CEST 2002 Paolo Molaro <lupus@ximian.com>
8221
8222         * appdomain.h, appdomain.c, class.c, object.c: protect MonoDomain
8223         data with a mutex.
8224
8225 2002-04-09  Dietmar Maurer  <dietmar@ximian.com>
8226
8227         * mempool.c (mono_mempool_alloc): only use g_malloc when
8228         absolutely necessary.
8229
8230 2002-04-08  Dietmar Maurer  <dietmar@ximian.com>
8231
8232         * mempool.c (MEM_ALIGN): hardcode MEM_ALIGN to 8
8233
8234         * class.c (mono_class_vtable): use domain mempool to allocate vtable
8235         (mono_class_proxy_vtable): use domain mempool
8236
8237 Mon Apr 8 17:17:04 CEST 2002 Paolo Molaro <lupus@ximian.com>
8238
8239         * appdomain.h, appdomain.c: split initialization that requires the
8240         execution engine support into mono_runtime_init().
8241
8242 2002-04-08  Dietmar Maurer  <dietmar@ximian.com>
8243
8244         * class.c (mono_class_init): don't include vtable inside MonoClass
8245         to save some memory, gather some statistics.
8246         (mono_class_vtable): use g_malloc instead of GC_malloc when possible
8247
8248 Sat Apr 6 20:07:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
8249
8250         * icall.c: internalcall implementation for ValueType.Equals().
8251
8252 2002-04-06  Dietmar Maurer  <dietmar@ximian.com>
8253
8254         * object.c (mono_message_init): moved 
8255         (mono_runtime_exec_main): new arch. independent impl.
8256         (mono_runtime_invoke_array): new method - like
8257         mono_runtime_invoke, but you can pass an array of objects.
8258         (mono_remoting_invoke): new arch. independent impl.
8259         (mono_message_invoke): new arch. independent impl.
8260         (mono_runtime_class_init): new arch. independent impl.
8261         (mono_runtime_object_init): new arch. independent impl.
8262
8263 Fri Apr 5 18:29:14 CEST 2002 Paolo Molaro <lupus@ximian.com>
8264
8265         * metadata.c, object.c, reflection.c: documented the exported
8266         functions.
8267
8268 Fri Apr 5 15:42:31 CEST 2002 Paolo Molaro <lupus@ximian.com>
8269
8270         * icall.c: simpler code to pass the assembly builder data to corlib.
8271         Implement GetNestedTypes() internalcall.
8272
8273 Thu Apr 4 21:46:48 CEST 2002 Paolo Molaro <lupus@ximian.com>
8274
8275         * class.c: warn if a type can't be loaded.
8276
8277 2002-04-04  Dietmar Maurer  <dietmar@ximian.com>
8278
8279         * image.h: typedef MonoImageOpenStatus
8280         * types.h: removed unused file
8281         
8282 2002-04-04  Dan Lewis  <dihlewis@yahoo.co.uk>
8283
8284         * icall.c: Enum_ToObject accepts enum value arguments.
8285
8286 Thu Apr 4 11:35:37 CEST 2002 Paolo Molaro <lupus@ximian.com>
8287
8288         * class.c: move initialization of properties, events and nested
8289         classes, so that they happen for interfaces, too.
8290
8291 Wed Apr 3 20:03:32 CEST 2002 Paolo Molaro <lupus@ximian.com>
8292
8293         * icall.c: cleanup some ugly casts in Array_SetValue*.
8294
8295 Wed Apr 3 19:49:53 CEST 2002 Paolo Molaro <lupus@ximian.com>
8296
8297         * icall.c: the values array fro enums is of the correct type, now.
8298         Implement (correctly) getFullName instead of assQualifiedName for
8299         MonoType.
8300         * reflection.h, reflection.c: added mono_type_get_name ().
8301
8302 Wed Apr 3 17:56:22 CEST 2002 Paolo Molaro <lupus@ximian.com>
8303
8304         * assembly.c, image.h: for each MonoImage, record from wich assembly
8305         it was loaded.
8306         * reflection.h, icall.c: added System_Reflection_Assembly_GetTypes().
8307         Make Type.Assembly work.
8308
8309 2002-04-03  Dietmar Maurer  <dietmar@ximian.com>
8310
8311         * debug-symfile.h: use char* instead of gpointer to avoid
8312         unnecessary casts.
8313
8314         * appdomain.c (mono_jit_info_table_find): use char* instead of gpointer
8315
8316         * icall.c (ves_icall_InternalExecute): impl. FielSetter
8317         (ves_icall_System_Array_SetValueImpl): removed strange MonoArray cast
8318
8319 2002-03-30  Dietmar Maurer  <dietmar@ximian.com>
8320
8321         * icall.c (mono_message_init): impl. (code cleanup)
8322         (ves_icall_InternalExecute): impl. FieldGetter
8323
8324         * class.c (mono_class_init): added exerimental EXT_VTABLE_HACK, if
8325         defined we call all (non-static)methods through the vtable. 
8326
8327 Fri Mar 29 18:09:08 CET 2002 Paolo Molaro <lupus@ximian.com>
8328
8329         * class.c: it seems GC_debug_malloc() makes the Boehm GC call the
8330         finalizer even though the memory is still referenced (and the chunk of
8331         memory is not freed).
8332
8333 Fri Mar 29 17:43:04 CET 2002 Paolo Molaro <lupus@ximian.com>
8334
8335         * assembly.c: fix brokeness.
8336
8337 Fri Mar 29 16:09:54 CET 2002 Paolo Molaro <lupus@ximian.com>
8338
8339         * class.c: kill some warnings. Check explicit interface method
8340         implementation also without considering the namespace.
8341         Load also literal strings in static class data.
8342
8343 2002-03-29  Miguel de Icaza  <miguel@ximian.com>
8344
8345         * assembly.c (default_assembly_name_resolver): Kill memory leak. 
8346         (default_assembly_name_resolver): Make the resolver take the
8347         "base" directory where the assembly was originally defined, so we
8348         can load DLLs that are in the same directory as the assembly that
8349         is being referenced.
8350
8351 2002-03-28  Dick Porter  <dick@ximian.com>
8352
8353         * file-io.h: 
8354         * file-io.c:
8355         * socket-io.c: 
8356         * unicode.h: 
8357         * unicode.c: Warning cleanups
8358
8359 Thu Mar 28 18:06:14 CET 2002 Paolo Molaro <lupus@ximian.com>
8360
8361         * object.h, reflection.h: use the correct type instead of MonoObject.
8362
8363 2002-03-28  Martin Baulig  <martin@gnome.org>
8364
8365         * debug-symfile.c (mono_debug_class_get): Don't look in referenced assemblies.
8366         (mono_debug_update_symbol_file): Initialize classes if necessary.
8367
8368 Thu Mar 28 15:58:43 CET 2002 Paolo Molaro <lupus@ximian.com>
8369
8370         * assembly.c, debug-helpers.c, image.c, image.h, metadata.c, pedump.c,
8371         rawbuffer.c, reflection.c, verify.c: mare warning cleanups.
8372
8373 Thu Mar 28 15:20:39 CET 2002 Paolo Molaro <lupus@ximian.com>
8374
8375         * assembly.h: fix function prototype.
8376         * metadata.h, metadata.c, object.h, private.h: get rid of warnings.
8377         * mono-endian.h: use const cast.
8378
8379 2002-03-28  Dietmar Maurer  <dietmar@ximian.com>
8380
8381         * icall.c (ves_icall_MonoMethodMessage_InitMessage): moved from message.c
8382
8383 Thu Mar 28 12:32:00 CET 2002 Paolo Molaro <lupus@ximian.com>
8384
8385         * loader.c: don't assert when a typeref can't be loaded, give
8386         a chance to the runtime to trow an exception instead.
8387         * loader.h: fix warning.
8388
8389 2002-03-28  Dietmar Maurer  <dietmar@ximian.com>
8390
8391         * class.c (mono_class_proxy_vtable): added proxy support
8392
8393 2002-03-27  Dan Lewis <dihlewis@yahoo.co.uk>
8394
8395         * icall.c: removed last of PAL calls, added System.Environment
8396         * file-io.h, file-io.c: MonoIO implementation
8397         * object.h, object.c: mono_string_to_utf16() now returns gunichar2*
8398
8399 Tue Mar 26 19:56:10 CET 2002 Paolo Molaro <lupus@ximian.com>
8400
8401         * appdomain.c: do not use the byte marker in ldstr table lookup.
8402         * debug-helpers.c: allow two ':' to separate class and method name.
8403         * object.c: allocate arrays bounds with the GC, too.
8404         * verify: add a few more checks.
8405
8406 Tue Mar 26 18:45:46 CET 2002 Paolo Molaro <lupus@ximian.com>
8407
8408         * reflection.c: output also literal strings. Allocate parameter data
8409         with GC_malloc() (thanks, Martin, for catching this!).
8410
8411 2002-03-26  Martin Baulig  <martin@gnome.org>
8412
8413         * debug-symfile.h (MonoDebugMethodInfo): Added `this_offset', don't
8414         include the `this' offset in the `param_offsets'.
8415
8416 2002-03-25  Martin Baulig  <martin@gnome.org>
8417
8418         * debug-symfile.c (mono_debug_update_symbol_file): Use a new
8419         mono_debug_get_class() function to get the classes. Added new
8420         relocation types for arrays and strings.
8421         (mono_debug_get_class): New static function to search in all
8422         referenced assemblies for a metadata token.
8423
8424         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 7.
8425
8426 Mon Mar 25 13:08:18 CET 2002 Paolo Molaro <lupus@ximian.com>
8427
8428         * reflection.h, reflection.c: use a gc-safe hash for hash tables that
8429         hold gc-allocated objects. Make the string heap a stream like the
8430         others. Removed duplicated code when writing stream info.
8431         Added asserts to catch possible buffer overflows. Set the sorted map
8432         for tables that need sorting. Added some documentation.
8433
8434 Mon Mar 25 13:04:56 CET 2002 Paolo Molaro <lupus@ximian.com>
8435
8436         * appdomain.h, appdomain.c, class.c, object.c: use a GC-safe hash table 
8437         for interned strings and vtables.
8438
8439 2002-03-24  Martin Baulig  <martin@gnome.org>
8440
8441         * icall.c (ves_icall_Type_GetFields): Reverse the list before storing
8442         it in the array since it was created with g_slist_prepend().
8443
8444 2002-03-24  Martin Baulig  <martin@gnome.org>
8445
8446         * debug-symfile.c (mono_debug_local_type_from_signature): Renamed
8447         to ves_icall_Debugger_MonoSymbolWriter_get_local_type_from_sig().
8448         (mono_debug_method_from_token): Renamed to
8449         ves_icall_Debugger_MonoSymbolWriter_method_from_token().
8450         (ves_icall_Debugger_DwarfFileWriter_get_type_token): New interncall.
8451
8452         * debug-symfile.c (MRT_type_sizeof, MRT_type_field_offset): New
8453         relocation types.
8454
8455         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 6.
8456
8457 2002-03-24  Martin Baulig  <martin@gnome.org>
8458
8459         * debug-symfile.c (mono_debug_local_type_from_signature): New func.
8460         (mono_debug_method_from_token): New func.
8461
8462         * icall.c (Mono.CSharp.Debugger.MonoSymbolWriter::get_local_type_from_sig):
8463         New interncall, calls mono_debug_local_type_from_signature().
8464         (Mono.CSharp.Debugger.MonoSymbolWriter::get_method): New interncall,
8465         calls mono_debug_method_from_token().
8466
8467 2002-03-23  Martin Baulig  <martin@gnome.org>
8468
8469         * unicode.c (ves_icall_iconv_get_char_count): The `count' argument
8470         specifies the number of bytes to be converted, not the array size.
8471         Return the number of chars, not the number of bytes.
8472         (ves_icall_iconv_get_chars): The `byteCount' argument
8473         specifies the number of bytes to be converted, not the array size.
8474
8475 2002-03-23  Martin Baulig  <martin@gnome.org>
8476
8477         * reflection.h (MonoReflectionSigHelper): New type.
8478
8479         * reflection.c (mono_reflection_sighelper_get_signature_local),
8480         (mono_reflection_sighelper_get_signature_local): New functions.
8481
8482         * icall.c (System.Reflection.Emit.SignatureHelper::get_signature_local),
8483         (System.Reflection.Emit.SignatureHelper::get_signature_field): New
8484         interncalls.
8485
8486 2002-03-23  Martin Baulig  <martin@gnome.org>
8487
8488         * rawbuffer.c (mono_raw_buffer_load_mmap): Use MAP_SHARED when
8489         is_writeable is set.
8490         (mono_raw_buffer_update): New function to write the modified map
8491         back to disk.
8492
8493         * debug-symfile.h (MonoDebugSymbolFile): Added `raw_contents_size'.
8494
8495         * debug-symfile.c (mono_debug_update_symbol_file): Call
8496         mono_raw_buffer_update() when done writing.
8497
8498 2002-03-23  Martin Baulig  <martin@gnome.org>
8499
8500         * debug-symfile.h (MONO_DEBUG_SYMBOL_FILE_VERSION): Increased to 5.
8501
8502         * debug-symfile.c: Added support for arguments and local variables.
8503
8504 2002-03-23  Dick Porter  <dick@ximian.com>
8505
8506         * debug-symfile.c: Remove extraneous 'include <elf.h>' that wasn't
8507         protected by ifdefs, hence breaking the w32 build.
8508
8509 Thu Mar 21 17:35:01 CET 2002 Paolo Molaro <lupus@ximian.com>
8510
8511         * object.c: implement is_interned() the right way.
8512
8513 2002-03-21  Martin Baulig  <martin@gnome.org>
8514
8515         * debug-symfile.[ch]: New files to handle debugging information
8516         files. There's also support to dynamically update these symbol
8517         files to include machine dependent information.
8518
8519 2002-03-20  Dietmar Maurer  <dietmar@ximian.com>
8520
8521         * threads.c (mono_thread_create): new function to create thread
8522         from C
8523
8524 2002-03-20  Martin Baulig  <martin@gnome.org>
8525
8526         * icall.c (ves_icall_InternalInvoke): Create a new object if the
8527         method is a constructor.
8528         (icall_map): Added "System.Reflection.MonoCMethod::InternalInvoke",
8529         points to ves_icall_InternalInvoke().
8530
8531 2002-03-20  Dan Lewis <dihlewis@yahoo.co.uk>
8532
8533         * file-io.c: Flush shouldn't throw exceptions.
8534
8535 2002-03-19  Dan Lewis <dihlewis@yahoo.co.uk>
8536
8537         * file-io.c: FileStream flush support; FileSetLength now
8538         restores file pointer.
8539
8540 Tue Mar 19 18:17:21 CET 2002 Paolo Molaro <lupus@ximian.com>
8541
8542         * class.c: set image for pointer classes.
8543
8544 2002/03/19  Nick Drochak <ndrochak@gol.com>
8545
8546         * sysmath.c: Forgot one.
8547
8548 2002-03-18  Miguel de Icaza  <miguel@ximian.com>
8549
8550         * sysmath.c: Avoid redefining existing names.
8551
8552 2002-03-18  Dan Lewis <dihlewis@yahoo.co.uk>
8553
8554         * sysmath.c, sysmath.h, icall.c, Makefile.am: math routines now
8555         handled by runtime as icall rather than dllimport from libm.so
8556         * file-io.c, file-io.h: fixed handle argument type.
8557
8558 2002-03-18  Dick Porter  <dick@ximian.com>
8559
8560         * reflection.c (mono_image_get_type_info): rename interface to
8561         iface, because of "#define interface struct" on windows.
8562
8563 Sat Mar 16 19:18:38 CET 2002 Paolo Molaro <lupus@ximian.com>
8564
8565         * class.c, class.h: rename and export mono_ptr_class_get().
8566         * metadata.c: support MONO_TYPE_ARRAY in MonoType compare.
8567         * reflection.c, reflection.h, icall.c: better/saner type name
8568         parsing and MonoType creation. Handle MONO_TYPE_ARRAY in
8569         method signatures.
8570
8571 2002-03-14  Dietmar Maurer  <dietmar@ximian.com>
8572
8573         * class.c (mono_class_init): removed hardcoded GHC_SLOT
8574
8575         * icall.c (ves_icall_InternalInvoke): impl.
8576
8577 Wed Mar 13 00:27:30 CET 2002 Paolo Molaro <lupus@ximian.com>
8578
8579         * reflection.c: output the interface map table, too.
8580
8581 2002-03-12  Dietmar Maurer  <dietmar@ximian.com>
8582
8583         * class.c (class_compute_field_layout): separate computation of 
8584         static field layout
8585
8586 2002-03-12  Dan Lewis <dihlewis@yahoo.co.uk>
8587
8588         * icall.c: added System.Buffer support.
8589         * file-io.c: moved file icalls from PAL to FileStream.
8590
8591 2002-03-12  Dietmar Maurer  <dietmar@ximian.com>
8592
8593         * icall.c (ves_icall_System_Object_GetHashCode): impl.
8594
8595 2002-03-11  Dietmar Maurer  <dietmar@ximian.com>
8596
8597         * icall.c (ves_icall_System_ValueType_GetHashCode): impl.
8598
8599 Mon Mar 11 14:45:42 CET 2002 Paolo Molaro <lupus@ximian.com>
8600
8601         * verify.c, verify.h: moved here the corlib/runtime consistency checks.
8602
8603 Mon Mar 11 11:12:23 CET 2002 Paolo Molaro <lupus@ximian.com>
8604
8605         * debug-helpers.{c,h}: moved here from monograph some useful functions
8606         to locate a method by name/signature in a class or image. Included
8607         also a small and flexible IL disassembler.
8608
8609 Fri Mar 8 16:29:29 CET 2002 Paolo Molaro <lupus@ximian.com>
8610
8611         * reflection.c: fixup tokens in methods with small header size, too.
8612
8613 2002-03-08  Dietmar Maurer  <dietmar@ximian.com>
8614
8615         * object.c (mono_string_to_utf8): remove assert(!error), instead
8616         print a warning. 
8617
8618 Thu Mar 7 18:55:15 CET 2002 Paolo Molaro <lupus@ximian.com>
8619
8620         * icall.c: update to the new mono_Array_class_get interface.
8621
8622 Thu Mar 7 17:23:26 CET 2002 Paolo Molaro <lupus@ximian.com>
8623
8624         * appdomain.c, object.c: Boehm-GC enable.
8625         * icall.c: make get_data_chunk() support split data requests.
8626         Ensure a class is initialized in more cases. Return only the first
8627         property found in GetProperties() or the compiler gets confused. 
8628         Implemented GetEvents(). Temporary fix to GetType(), needs rewriting.
8629         * reflection.h, reflection.c: add fixup mechanism for field and method
8630         tokens. Initialize assembly->typeref in a single place. Output
8631         properties after events. Support custom attributes for events, too.
8632         Typo fix for paramter custom attrs.
8633
8634 2002-03-07  Martin Baulig  <martin@gnome.org>
8635
8636         * icall.c (ves_icall_System_Array_FastCopy): Small fix.
8637
8638 2002-03-07  Dietmar Maurer  <dietmar@ximian.com>
8639
8640         * class.c (mono_array_class_get): fix. for multi. dim. arrays
8641
8642 2002-03-06  Martin Baulig  <martin@gnome.org>
8643
8644         * icall.c (ves_icall_System_Array_CreateInstanceImpl): Make this work with
8645         non-zero lower bounds. See testcases #F10-#F13.
8646
8647 2002-03-05  Martin Baulig  <martin@gnome.org>
8648
8649         * exception.c (mono_get_exception_argument_out_of_range): New exception.
8650
8651         * icall.c (ves_icall_System_Array_GetValue): Moved actual implementation to
8652         ves_icall_System_Array_GetValue(), only calculate the absolute array position
8653         here.
8654         (ves_icall_System_Array_SetValue): Likewise.
8655         (ves_icall_System_Array_GetValueImpl): New interncall. Takes an array position
8656         as argument and does the actual work. This function is used when copying a
8657         multi-dimensional array.
8658         (ves_icall_System_Array_SetValueImpl): Almost completely rewrote this. It can
8659         now do all the widening conversions of value types.
8660         (ves_icall_System_Array_CreateInstanceImpl): Implemented.
8661
8662 Tue Mar 5 18:14:01 CET 2002 Paolo Molaro <lupus@ximian.com>
8663
8664         * class.c: remove some magic numbers and use the smbolic names,
8665         instead. Added init_events() to load event info at class init time.
8666         * metadata.h, metadata.c: added mono_metadata_events_from_typedef()
8667         and mono_metadata_methods_from_event().
8668         * reflection.h, reflection.c: added support for writing out the evnets
8669         related information.
8670
8671 Mon Mar 4 20:32:43 CET 2002 Paolo Molaro <lupus@ximian.com>
8672
8673         * reflection.h, icall.c: use a different method (GetInterfaces)
8674         to gather interface info and add isbyref, isprimitive and
8675         ispointer to the ves_icall_get_type_info() return value.
8676
8677 Mon Mar 4 11:22:26 CET 2002 Paolo Molaro <lupus@ximian.com>
8678
8679         * class.h: stared adding support for events.
8680         * icall.c: split find_members implementation. Added debug icall to get
8681         the address of an object.
8682         * reflection.c: handle TypeBuilders in mono_type_get_object().
8683
8684 2002-03-01  Martin Baulig  <martin@gnome.org>
8685
8686         * icall.c (ves_icall_System_Array_GetLength): This must throw an
8687         ArgumentOutOfRangeException(), not an ArgumentException().
8688         (ves_icall_System_Array_GetLowerBound): Likewise.
8689         (ves_icall_System_Array_GetValue): Improved argument checking.
8690         (ves_icall_System_Array_SetValue): Improved argument checking.
8691
8692 2002-03-01  Martin Baulig  <martin@gnome.org>
8693
8694         * icall.c (ves_icall_System_Array_GetValue): Raise an exception when
8695         called with invalid arguments rather than just dying with g_assert().
8696         (ves_icall_System_Array_SetValue): Likewise.
8697         (ves_icall_System_Array_CreateInstanceImpl): Don't g_assert_not_reached(),
8698         raise a NotImplementedException instead.
8699         (ves_icall_System_Array_GetLength): Added argument checking.
8700         (ves_icall_System_Array_GetLowerBound): Added argument checking.
8701
8702 2002-03-01  Dietmar Maurer  <dietmar@ximian.com>
8703
8704         * object.h (mono_assert): new macros mono_assert and
8705         mono_assert_not_reached
8706
8707 2002-02-28  Martin Baulig  <martin@gnome.org>
8708
8709         * icall.c: Rename "System::String::Intern" to "System::String::_Intern"
8710         and "System::String::IsInterned" to "System::String::_IsInterned".
8711
8712 Thu Feb 28 19:19:35 CET 2002 Paolo Molaro <lupus@ximian.com>
8713
8714         * icall.c: remove hacks for typebuilder. Added icall to create a
8715         modified type from a tybebuilder.
8716         * reflection.c: removed hacks for TypeBuilder. Create also a MonoImage
8717         in mono_image_basic_init (). Added mono_reflection_setup_internal_class ()
8718         to create a backing MonoClass for a TypeBuilder.
8719
8720 Thu Feb 28 15:35:51 CET 2002 Paolo Molaro <lupus@ximian.com>
8721
8722         * class.c, class.h: more refactoring of class init.
8723         Export mono_class_setup_mono_type() and mono_class_setup_parent().
8724
8725 Thu Feb 28 12:33:41 CET 2002 Paolo Molaro <lupus@ximian.com>
8726
8727         * marshal.c, marshal.h: start of marshaling interface.
8728
8729 Wed Feb 27 22:15:17 CET 2002 Paolo Molaro <lupus@ximian.com>
8730
8731         * icall.c: fix order in assembly qualified name icall.
8732
8733 Wed Feb 27 18:45:03 CET 2002 Paolo Molaro <lupus@ximian.com>
8734
8735         * class.c: do not free str, since we store it in the hash table.
8736         * reflection.h: add label field to MonoILExceptionInfo.
8737         * reflection.c: handle references to more than one assembly. Handle
8738         case when there isn't a module created in the assembly.
8739
8740 Wed Feb 27 12:35:10 CET 2002 Paolo Molaro <lupus@ximian.com>
8741
8742         * class.c: Fix typo. Start refactoring of class init code.
8743
8744 Wed Feb 27 12:23:00 CET 2002 Paolo Molaro <lupus@ximian.com>
8745
8746         * appdomain.c: exit with 1 on error.
8747         * class.c: we already have the name in MonoClassField.
8748         * image.c, image.h, metadata.c, pedump.c: use directly a pointer in
8749         MonoStreamHeader instead of an offset of image->raw_metadata.
8750
8751 2002-02-26  Miguel de Icaza  <miguel@ximian.com>
8752
8753         * appdomain.c (mono_init): Be even more descriptive about the error.
8754
8755 Tue Feb 26 16:18:07 CET 2002 Paolo Molaro <lupus@ximian.com>
8756
8757         * appdomain.c: give the user an informative message when corlib can't
8758         be loaded.
8759
8760 2002-02-26  Martin Baulig  <martin@gnome.org>
8761
8762         * icall.c (ves_icall_System_CurrentTimeZone_GetTimeZoneData):
8763         New icall to get the time zone data.
8764
8765 Mon Feb 25 15:51:51 CET 2002 Paolo Molaro <lupus@ximian.com>
8766
8767         * reflection.c: set virtual and raw size of section correctly.
8768         * threads.c: transfer domain information to newly created threads.
8769
8770 Fri Feb 22 18:55:57 CET 2002 Paolo Molaro <lupus@ximian.com>
8771
8772         * class.c: when instancing a class in a domain, load the default
8773         vaules for static fields from the constant table. Fix System.Enum to
8774         not be an enum.
8775         * icall.c: implement Object::GetType() internalcall. Implemented
8776         MonoField::GetValue() internalcall. Avoid SEGV in search_method().
8777         Fixed checking of binding flags in find_members().
8778         * metadata.c, metadata.h: introduce mono_metadata_type_hash().
8779         * reflection.c: handle enumerations when writing to the constant
8780         table. Use a different object cache for types.
8781
8782
8783 2002-02-22  Dietmar Maurer  <dietmar@ximian.com>
8784
8785         * object.c (mono_object_isinst): fix for arrays
8786
8787         * icall.c (ves_icall_type_is_subtype_of): fix for 2 interfaces
8788
8789 Thu Feb 21 21:00:13 CET 2002 Paolo Molaro <lupus@ximian.com>
8790
8791         * object.c: don't use mprotect ()  and fix intern pool hash table
8792         lookup for big endian systems.
8793
8794 Thu Feb 21 19:30:29 CET 2002 Paolo Molaro <lupus@ximian.com>
8795
8796         * icall.c: change type_is_subtype_of () signature.
8797
8798 2002-02-21  Mark Crichton  <crichton@gimp.org>
8799
8800         * rand.c, rand.h: Added random number generator for
8801         System.Security.Cryptography classes.
8802
8803         * exception.c, exception.h: Added mono_get_exception_not_implemeted.
8804
8805         * icall.c: Added System.Security.Cryptography calls.
8806
8807 Thu Feb 21 16:45:34 CET 2002 Paolo Molaro <lupus@ximian.com>
8808
8809         * class.c, icall.c, metadata.c: better support for pointer types.
8810         Create a class for them as suggested by dietmar. Fix TYPE_ARRAY class.
8811         * reflection.c: Add support for getting custom attrs for properties
8812         and simplify some code.
8813
8814 Wed Feb 20 22:20:29 CET 2002 Paolo Molaro <lupus@ximian.com>
8815
8816         * icall.c: change getToken () and add custom attribute GetBlob()helper
8817         method.
8818         * reflection.h: add custom attrs array to the reflection builder structures.
8819         * reflection.c: encode and emit custom attributes for all the relevant
8820         reflection objects. Cache fieldref and methodref tokens. Change
8821         mono_image_create_token() interface to take a MonoDynamicAssembly.
8822         More complete custom attributes decoder. Load custom attributes for
8823         Assembly, Field, Method and Constructor objects, too. Make the
8824         returned array an Attribute[] one, not object[]. Added
8825         mono_reflection_get_custom_attrs_blob() to encode the arguments of a
8826         custom attribute constructor.
8827
8828 2002-02-20  Dick Porter  <dick@ximian.com>
8829
8830         * icall.c:
8831         * rawbuffer.c:
8832         * socket-io.c: Windows portability fixes (sometimes just ifdeffing
8833         problem code out for now).
8834
8835 2002-02-19  Radek Doulik  <rodo@ximian.com>
8836
8837         * object.c (mono_ldstr): use hash table to avoid multiple swapping
8838
8839 Tue Feb 19 20:23:11 CET 2002 Paolo Molaro <lupus@ximian.com>
8840
8841         * icall.c: register the GetCustomAttributes method.
8842         * object.c, object.h: add mono_string_new_len ().
8843         * reflection.h, reflection.c: added mono_runtime_invoke(),
8844         mono_install_runtime_invoke(). Added
8845         mono_reflection_get_custom_attrs () to load custom attributes and
8846         create the attribute objects.
8847
8848 2002-02-19  Dick Porter  <dick@ximian.com>
8849         * threads-dummy-types.c:
8850         * threads-dummy-types.h:
8851         * threads-dummy.c:
8852         * threads-dummy.h:
8853         * threads-pthread-types.c:
8854         * threads-pthread-types.h:
8855         * threads-pthread.c:
8856         * threads-pthread.h:  Deleted obsolete files
8857
8858 2002-02-19  Dietmar Maurer  <dietmar@ximian.com>
8859
8860         * class.c (mono_class_vtable): runtime init the class when we
8861         allocate static class data.
8862
8863         * icall.c (ves_icall_System_Array_SetValue): check for null values.
8864
8865         * appdomain.c (mono_domain_transfer_object): impl. hack for Arrays
8866         and String - but we will need generic marshalling support in the
8867         future. 
8868         (mono_init): set the domain name in a ms compatible way
8869
8870         * object.c (mono_string_new_utf16): bug fix: use char[] instead of
8871         String[].
8872
8873 2002-02-18  Dietmar Maurer  <dietmar@ximian.com>
8874
8875         * object.c (mono_array_clone): use alloca() instead of g_malloc  
8876         for sizes
8877
8878         * appdomain.c (mono_domain_unload): impl.
8879
8880 Mon Feb 18 15:52:20 CET 2002 Paolo Molaro <lupus@ximian.com>
8881
8882         * appdomain.c, object.c: fix intern pool implementation.
8883         * class.c: fix alignment code.
8884
8885 2002-02-16  Radek Doulik  <rodo@ximian.com>
8886
8887         * icall.c (ves_icall_System_Enum_ToObject): in case of big endian
8888         and s2 > s1, just copy lower bytes to be compatible with little
8889         endian (i.e. 64bit value & 0xffffffff --> 32bit value)
8890         (ves_icall_System_Enum_ToObject): and likewise for s1 > s2
8891
8892         * unicode.c (ves_icall_iconv_new_encoder): decide on big_endian,
8893         force big_endian to be 1 for big endian machines 
8894         (ves_icall_iconv_new_decoder): ditto
8895
8896 2002-02-16  Jeffrey Stedfast  <fejj@ximian.com>
8897
8898         * socket-io.c (convert_sockopt_level_and_name): If the system
8899         doesn't define SOL_IP or SOL_TCP, get them by hand using
8900         getprotobyname() and caching the values (because this could be a
8901         slow operation).
8902         (ves_icall_System_Net_Sockets_Socket_SetSocketOption_internal):
8903         Use the appropriate struct when the system does support it. Ie,
8904         not all systems have struct ip_mreqn so use struct ip_mreq when
8905         appropriate.
8906
8907 Fri Feb 15 18:15:44 CET 2002 Paolo Molaro <lupus@ximian.com>
8908
8909         * reflection.c: handle finally clauses.
8910
8911 Fri Feb 15 15:06:33 CET 2002 Paolo Molaro <lupus@ximian.com>
8912
8913         * socket-io.c: use g_snprintf() instead of snprintf.
8914
8915 2002-02-14  Jeffrey Stedfast  <fejj@ximian.com>
8916
8917         * reflection.c (mono_param_get_objects): Cast second argument to
8918         mono_method_get_param_names to a const char** to silence the
8919         compiler warning.
8920
8921         * appdomain.c (mono_domain_assembly_open): Put parens around the
8922         truth statement in the for-loop.
8923
8924         * unicode.c (iconv_convert): Got rid of a compiler warning about
8925         int i being unused when the system has a new iconv.
8926         (iconv_get_length): Same.
8927
8928         * image.c (load_class_names): Cast the second argument to
8929         g_hash_table_insert() to char* to hush compiler warnings about the
8930         arg being a const.
8931         (mono_image_open): Same here.
8932
8933         * socket-io.c: Don't conditionally include sys/filio.h or
8934         sys/sockio.h here anymore since we now get them from
8935         io-layer/io-layer.h
8936         (inet_pton): If the system doesn't support inet_aton, implement
8937         using inet_addr and also #define INADDR_NONE if it isn't defined
8938         by the system.
8939
8940 Thu Feb 14 19:01:06 CET 2002 Paolo Molaro <lupus@ximian.com>
8941
8942         * metadata.c, metadata.h: added function to get packing and size info
8943         of a typedef.
8944         * reflection.h, reflection.c: handle field RVA data. Save info about
8945         the table layout if needed. Assign typedef indexes to all the types
8946         before dumping the info about them to avoid forward reference problems.
8947
8948 2002-02-14  Dietmar Maurer  <dietmar@ximian.com>
8949
8950         * socket-io.c (convert_sockopt_level_and_name): ifdef
8951         SO_ACCEPTCONN because it is not defined on my system (old debian)
8952
8953 Thu Feb 14 11:49:30 CET 2002 Paolo Molaro <lupus@ximian.com>
8954
8955         * opcode.c: use stddef.h to get NULL.
8956
8957 2002-02-14  Jeffrey Stedfast  <fejj@ximian.com>
8958
8959         * socket-io.c: conditionally include sys/filio.h and sys/sockio.h
8960         for FIONBIO, FIONREAD and SIOCATMARK.
8961         (ves_icall_System_Net_Dns_GetHostByAddr_internal): SunOS doesn't
8962         define INADDR_NONE and besides, inet_addr() is deprecated and
8963         should not be used. Use inet_pton() instead - it also has the
8964         added bonus that it can easily handle IPv6 addresses as well.
8965         (inet_pton): Implement using inet_aton() ifndef HAVE_INET_PTON.
8966
8967 Wed Feb 13 23:00:21 CET 2002 Paolo Molaro <lupus@ximian.com>
8968
8969         * decimal.c: remove _MSC_VER conditional.
8970
8971 2002-02-13  Dick Porter  <dick@ximian.com>
8972
8973         * socket-io.c: 
8974         * icall.c: Internal calls for Blocking, Select, Shutdown,
8975         GetSocketOption and SetSocketOption
8976
8977 Wed Feb 13 19:20:01 CET 2002 Paolo Molaro <lupus@ximian.com>
8978
8979         * assembly.cs: better resolver: use it instead of some kludgy
8980         code.
8981
8982 Wed Feb 13 18:25:55 CET 2002 Paolo Molaro <lupus@ximian.com>
8983
8984         * reflection.c: the best way to speed-up the compiler is to avoid
8985         infinite loops.
8986
8987 2002-02-13  Dietmar Maurer  <dietmar@ximian.com>
8988
8989         * class.c (mono_class_vtable): changed the object layout
8990         (obj->vtable->class). 
8991         (mono_class_create_from_typespec): consider MONO_TYPE_PTR
8992
8993 Tue Feb 12 20:06:01 CET 2002 Paolo Molaro <lupus@ximian.com>
8994
8995         * assembly.c: look for assemblies in the assembly dir, too.
8996
8997 Tue Feb 12 14:03:42 CET 2002 Paolo Molaro <lupus@ximian.com>
8998
8999         * class.c: fix thinko in mono_class_from_type().
9000
9001 Mon Feb 11 19:43:51 CET 2002 Paolo Molaro <lupus@ximian.com>
9002
9003         * exception.h, exception.c: added TypeLoadException.
9004         * object.h, object.c: added mono_array_clone ().
9005         * icall.c: handle throwOnError in AssemblyGetType().
9006         Added Array.Clone().
9007         * opcode.h, opcode.c: use a single value for the opcode val.
9008         Compile fix for non-gcc compilers.
9009
9010 Fri Feb 8 12:26:37 CET 2002 Paolo Molaro <lupus@ximian.com>
9011
9012         * opcodes.c, opcodes.h: export interesting info about opcodes.
9013
9014 2002-02-05  Dietmar Maurer  <dietmar@ximian.com>
9015
9016         * object.h (MONO_CHECK_ARG, MONO_CHECK_ARG_NULL): new macro for
9017         icalls. 
9018
9019         * class.c (class_compute_field_layout): set element_class for enums
9020         (mono_class_create_from_typedef): set element_class for normal classes
9021
9022         * icall.c (ves_icall_System_Enum_get_value): impl.
9023
9024         * class.c (mono_class_create_from_typedef): do not set valuetype
9025         flag for System.ValueType and System.Enum
9026
9027 2002-02-04  Dietmar Maurer  <dietmar@ximian.com>
9028
9029         * unicode.c (iconv_convert): fix big endian problem.
9030
9031 Fri Feb 1 16:13:20 CET 2002 Paolo Molaro <lupus@ximian.com>
9032
9033         * class.c: add asserts if we are ever going to scribble over memory.
9034         * socket-io.c: not all systems have AF_IRDA defined.
9035
9036 2002-01-31  Dietmar Maurer  <dietmar@ximian.com>
9037
9038         * class.c (class_compute_field_layout): do not consider static
9039         fields to compute alignment
9040
9041 2002-01-25  Dietmar Maurer  <dietmar@ximian.com>
9042
9043         * appdomain.c (mono_appdomain_get): impl.
9044         (ves_icall_System_AppDomain_ExecuteAssembly): impl.
9045
9046 Thu Jan 24 12:59:23 CET 2002 Paolo Molaro <lupus@ximian.com>
9047
9048         * icall.c: ignore "file://" prefix when loading an assembly.
9049
9050 2002-01-23  Dick Porter  <dick@ximian.com>
9051
9052         * socket-io.c:
9053         * icall.c:
9054         * Makefile.am: Added socket support
9055
9056 2002-01-23  Miguel de Icaza  <miguel@ximian.com>
9057
9058         * icall.c (ves_icall_appdomain_get_default_assemblies): put this
9059         code back.  This should return the assemblies that are loaded by
9060         the runtime on behalf of an application domain. 
9061
9062         The current implementation is still broken, it just returns every
9063         assembly loaded, but until we get real applications domain this
9064         will do.
9065
9066 2002-01-23  Dietmar Maurer  <dietmar@ximian.com>
9067
9068         * icall.c (ves_icall_appdomain_get_cur_domain): runtime_init the
9069         AppDomain object.
9070
9071 2002-01-23  Miguel de Icaza  <miguel@ximian.com>
9072
9073         * icall.c (ves_icall_appdomain_get_cur_domain): Cache the value of
9074         the mono_class_from_name lookup.
9075         (ves_icall_get_parameter_info): ditto.
9076         (ves_icall_appdomain_get_assemblies, add_assembly): Implement new internal
9077         method.
9078         (ves_icall_System_Reflection_Assembly_get_code_base): Another new call.
9079
9080 Tue Jan 22 22:43:47 CET 2002 Paolo Molaro <lupus@ximian.com>
9081
9082         * class.c: load also nested classes on class init.
9083         System.ValueType instance methods gets passed boxed
9084         values, unless methods in derived classed that get a pointer to the
9085         data.
9086         * icall.c: use better name parsing code in GetType().
9087         * image.c, image.h: add mono_image_loaded ().
9088         * metadata.c, metadata.h: add mono_metadata_nesting_typedef ().
9089         * reflection.c, reflection.h: added mono_reflection_parse_type().
9090
9091 2002-01-22  Veronica De Santis <veron78@interfree.it>
9092
9093         * icall.c : Added mapping of internal calls for Manual and Auto reset events
9094         * threads.c : Added the implementation of internal calls for events
9095         * threads.h : Added prototypes of internal calls for events
9096         
9097 2002-01-21  Radek Doulik  <rodo@ximian.com>
9098
9099         * icall.c (ves_icall_InitializeArray): swap bytes on big endians
9100
9101 2002-01-21  Dietmar Maurer  <dietmar@ximian.com>
9102
9103         * class.c (mono_class_init): set min_align to 1 (instead of 0)
9104         (mono_class_value_size): use min_align
9105
9106 2002-01-20  Dick Porter  <dick@ximian.com>
9107
9108         * threads.h:
9109         * threads.c: Replaced all instances of WapiHandle * with HANDLE,
9110         so it compiles on w32.
9111
9112 2002-01-17  Dietmar Maurer  <dietmar@ximian.com>
9113
9114         * metadata.c (mono_type_stack_size): impl.
9115
9116         * class.c (mono_class_get_field): impl. memberref token
9117
9118 2002-01-16 Veronica De Santis <veron78@@interfree.it>
9119
9120         * icall.h : Added the internal calls mapping for CreateMutex_internal
9121                     and ReleaseMutex_internal.
9122         * threads.h : Added the prototype of mutexes internal calls.
9123         * threads.c : Added the implementations of mutexes internal calls.
9124
9125 Tue Jan 15 22:47:57 CET 2002 Paolo Molaro <lupus@ximian.com>
9126
9127         * metaparse.h: removed unused file.
9128         * reflection.c, reflection.h: added stream_data_align () function 
9129         to align data in streams and keep stream aligned. Add support for
9130         exception support in method headers.
9131
9132 Tue Jan 15 19:42:50 CET 2002 Paolo Molaro <lupus@ximian.com>
9133
9134         * unicode.c: make iconv_convert () return the number of bytess written
9135         in the output buffer.
9136
9137 2002-01-15  Dick Porter  <dick@ximian.com>
9138         * threads.c: Make the runtime's idea of infinite timeouts coincide
9139         with the class library's
9140
9141         Fix a particularly egregious bug in mono_thread_cleanup(). That
9142         code was so utterly bogus it must have been written on a Monday.
9143
9144 Mon Jan 14 17:01:03 CET 2002 Paolo Molaro <lupus@ximian.com>
9145
9146         * reflection.h: add subtypes field to TypeBuilder.
9147         * reflection.c: encode constants for literal fields.
9148         Handle subtypes. Fix user string token (and add a zero byte)
9149         at the end.
9150         
9151 2002-01-14  Dietmar Maurer  <dietmar@ximian.com>
9152
9153         * class.c (mono_class_init): bug fix: assign slot numbers for
9154         abstract methods.
9155
9156 Fri Jan 11 18:54:42 CET 2002 Paolo Molaro <lupus@ximian.com>
9157
9158         * reflection.c: don't try to output a code RVA for abstract methods.
9159         Small fixes for method header format. Output parameter info to the
9160         ParamDef table. Save method overriding info to MethodImpl table.
9161         Fix property support. Allow typedef.extends to be a type in the
9162         building assembly.
9163         * verify.c: fix off-by-one error.
9164
9165 Thu Jan 10 19:36:27 CET 2002 Paolo Molaro <lupus@ximian.com>
9166
9167         * class.c: fix mono_class_from_mono_type () for szarray types.
9168         Remove unused cache check in mono_class_from_type_spec().
9169         * icall.c: *type_from_name () functions handle simple arrays and byref.
9170         * reflection.c: handle byref and szarray types. Handle methods without
9171         body (gets P/Invoke compilation working). Handle types and fields in
9172         get_token ().
9173         * reflection.h: add rank to MonoTypeInfo.
9174
9175 2002-01-10  Dick Porter  <dick@ximian.com>
9176
9177         * threads.c: Implemented WaitAll(), WaitAny() and WaitOne()
9178         internal calls
9179
9180 Wed Jan 9 19:27:13 CET 2002 Paolo Molaro <lupus@ximian.com>
9181
9182         * icall.c: initialize class in type_from_handle ().
9183         Loop also in parent classes for get_method ().
9184         * reflection.c: properly encode class and valuetype types.
9185         Start on encoding TypeBuilder types. Handle fieldrefs.
9186         Use correct length when registering a user string.
9187         Handle ConstructorBuilder and MonoMethod in get_token ().
9188         Make mono_type_get_object () aware of cached types.
9189         * object.c: back out change to mono_string_new ().
9190
9191 Tue Jan 8 22:47:44 EST 2002 Matt Kimball <matt@kimball.net>
9192         * object.c: mono_string_new should return a NULL when the string 
9193         passed in is NULL -- not try to deference it.
9194         
9195 Sat Jan 5 15:48:04 CET 2002 Paolo Molaro <lupus@ximian.com>
9196
9197         * icall.c: hack to make IsSubType work for TypeBuilders.
9198         * reflection.c: emit constructors before methods.
9199         Retrieve param names in mono_param_get_objects().
9200
9201 2002/01/05  Nick Drochak  <ndrochak@gol.com>
9202
9203         * Makefile.am: fix list of headers and sources so automake 1.5
9204         doesn't complain. Removed \# at end of list.
9205
9206 Thu Jan 3 23:17:17 CET 2002 Paolo Molaro <lupus@ximian.com>
9207
9208         * reflection.c: get token for a method ref. Set return type of
9209         constructor to void.
9210         * loader.c: debug message.
9211         * class.c: typo fix.
9212
9213 Mon Dec 24 17:18:10 CET 2001 Paolo Molaro <lupus@ximian.com>
9214
9215         * icall.c: fix array init with rank > 1. FindMembers
9216         loops in parent class as well.
9217         * image.c: do not insert nested types in name cache.
9218         * reflection.c: warning fix.
9219         * reflection.h: add override method (for interface impl).
9220
9221 Mon Dec 24 16:16:56 CET 2001 Paolo Molaro <lupus@ximian.com>
9222
9223         * metadata.c: fix customattr decoding.
9224
9225 2001-12-21  Miguel de Icaza  <miguel@ximian.com>
9226
9227         * rawbuffer.cs: Added native Win32 implementation, avoids using
9228         mmap on Cygwin.  This patch is from Dan Lewis (dihlewis@yahoo.co.uk)
9229
9230 Thu Dec 20 20:11:26 CET 2001 Paolo Molaro <lupus@ximian.com>
9231
9232         * class.c: make the low-level routines handle the cache.
9233
9234 Thu Dec 20 15:20:35 CET 2001 Paolo Molaro <lupus@ximian.com>
9235
9236         * image.c: fopen (file, "rb") ("David Dawkins" <david@dawkins.st>).
9237
9238 Tue Dec 18 18:50:00 CET 2001 Paolo Molaro <lupus@ximian.com>
9239
9240         * class.c: fix mono_array_element_size() for objects.
9241         * class.h, class.c: add properties to MonoClass and load them
9242         at init time.
9243         * icall.c: check with isinst() when assigning a value to an array
9244         instead of requiring the classes to match exactly.
9245         Implemented icall for System.Type::GetType().
9246         Implemented icalls to get ParameterInfo, ProprtyInfo and info about
9247         enums. Handle bindingflags when looking for methods and fields.
9248         * metadata.h, metadata.c: implemented mono_metadata_properties_from_typedef()
9249         and mono_metadata_methods_from_property().
9250         * reflection.h, reflection.c: added structures for propreties,
9251         parameters and enums. Implemented mono_property_get_object() and
9252         mono_param_get_objects().
9253
9254 2001-12-18  Dick Porter  <dick@ximian.com>
9255
9256         * file-io.c: Use mono_string_to_utf16() instead of
9257         mono_string_chars()
9258
9259         * object.c: Added mono_string_to_utf16(), which copies the non
9260         NULL-terminated MonoString into a new double-null-terminated
9261         buffer.
9262
9263 2001-12-17  Dietmar Maurer  <dietmar@ximian.com>
9264
9265         * icall.c (ves_icall_System_DateTime_GetNow): added EPOCH adjustment
9266
9267 2001-12-16  Dietmar Maurer  <dietmar@ximian.com>
9268
9269         * file-io.c: raise exceptions if handle is invalid.
9270
9271 Thu Dec 13 20:27:08 CET 2001 Paolo Molaro <lupus@ximian.com>
9272
9273         * assembly.c: yet another check for mscorlib.
9274         * class.c, class.h: load nesting info for classes.
9275         * icall.c: many new functions to support the Reflection classes.
9276         * metadata.c, metadata.h: mono_metadata_nested_in_typedef() added.
9277         * reflection.h, reflection.c: mono_image_create_token(),
9278         mono_assembly_get_object(), mono_type_get_object(),
9279         mono_method_get_object(), mono_field_get_object(): methods to return
9280         objects that parallel the C representation of assemblies, types,
9281         methods, fields.
9282
9283 2001-12-11  Dick Porter  <dick@ximian.com>
9284
9285         * icall.c:
9286         * file-io.c: Internal calls for file IO.
9287
9288 Thu Dec 6 16:21:30 CET 2001 Paolo Molaro <lupus@ximian.com>
9289
9290         * tabledefs.h: missing FileAttributes.
9291         * verify.h, verify.c: use is_valid_string () to simplify and check for
9292         valid strings more correctly. Fix warnings and speeling.
9293         Check more tables: Filed, File, ModuleRef, StandAloneSig.
9294         Check code: branches, maxstack, method calls.
9295
9296 2001-12-04  Dietmar Maurer  <dietmar@ximian.com>
9297
9298         * object.c (mono_object_allocate): removed static, so that the jit
9299         can allocate value types.
9300
9301         * icall.c (ves_icall_System_DateTime_GetNow): impl.
9302
9303 Mon Dec 3 17:02:01 CET 2001 Paolo Molaro <lupus@ximian.com>
9304
9305         * class.c: init enum types right away and register the
9306         token->MonoClass map in mono_class_create_from_typedef ().
9307         * verify.h, verify.c: first cut of the verifier.
9308         * pedump.c: add --verify switch to verify metadata tables.
9309         * tabledefs.h: add some missing enums.
9310
9311 2001-11-30  Dietmar Maurer  <dietmar@ximian.com>
9312
9313         * class.c (mono_install_runtime_class_init): impl.
9314         (mono_class_init): renamed mono_class_metadata_init to
9315         mono_class_init, also removed the metadata_inited flag
9316
9317         * object.c (mono_object_isinst): use faster algorithm
9318
9319 2001-11-30  Radek Doulik  <rodo@ximian.com>
9320
9321         * mono-endian.h: reverted last change
9322         added function prototypes
9323
9324         * Makefile.am (libmetadata_a_SOURCES): reverted my last change and
9325         add mono-endian.c back
9326
9327         * mono-endian.c: returned back, as Paolo pointed out, it's needed
9328         for unaligned access, I've mistaked it with endianess. I am
9329         sorry.
9330         (mono_read16): fix reverted endianess
9331         (mono_read64): ditto
9332         (mono_read32): ditto
9333
9334 2001-11-30  Dick Porter  <dick@ximian.com>
9335
9336         * exception.c: Implement mono_exception_from_name()
9337
9338 Fri Nov 30 12:01:02 CET 2001 Paolo Molaro <lupus@ximian.com>
9339
9340         * metadata.h, metadata.c: remove params_size and locals_size and their
9341         calculation from the metadata code: they are only usefult to the
9342         interp.
9343
9344 2001-11-29  Radek Doulik  <rodo@ximian.com>
9345
9346         * object.c (mono_ldstr): swap bytes here, it's probably not the
9347         best place, but works for me now, I'll redo it once I know mono
9348         better, also note that I add PROT_WRITE and don't reset back, also
9349         note that it's only affects big endians, so x86 should be OK
9350
9351         * mono-endian.h (read16): use just glib macros for both endians
9352
9353         * mono-endian.c: removed as glib macros are used in in
9354         mono-endian.h so we don't need to care about endianess for read
9355         macros as glib does that for us already
9356
9357 Thu Nov 29 18:20:58 CET 2001 Paolo Molaro <lupus@ximian.com>
9358
9359         * class.h, class.h: take minimum alignment into consideration so
9360         that the fields of a class remain aligned also when in an array.
9361
9362 Tue Nov 27 16:39:01 CET 2001 Paolo Molaro <lupus@ximian.com>
9363
9364         * loader.h, loader.c: add mono_method_get_param_names().
9365         * class.c: 0-init class fields.
9366
9367 2001-11-26  Dick Porter  <dick@ximian.com>
9368
9369         * icall.c:
9370         * threads-types.h:
9371         * threads.c: New file that handles System.Threading on all platforms
9372
9373         * object.c: 
9374         * object.h: Remove the synchronisation struct from MonoObject,
9375         replace it with a pointer that gets initialised on demand
9376
9377         * Makefile.am: Replace all the system-specific threading code with
9378         a single file that uses the new wrapper library
9379
9380 Mon Nov 19 11:37:14 CET 2001 Paolo Molaro <lupus@ximian.com>
9381
9382         * class.c, class.h: add mono_install_trampoline() so that the runtime
9383         can register a function to create a trampoline: removes the ugly
9384         requirement that a runtime needed to export arch_create_jit_trampoline.
9385         * object.h, object.c: added mono_install_handler() so that the runtime
9386         can install an handler for exceptions generated in C code (with
9387         mono_raise_exception()). Added C struct for System.Delegate.
9388         * pedump.c: removed arch_create_jit_trampoline.
9389         * reflection.c: some cleanups to allow registering user strings and
9390         later getting a token for methodrefs and fieldrefs before the assembly
9391         is built.
9392         * row-indexes.h: updates and fixes from the new ECMA specs.
9393
9394 Thu Nov 15 17:44:49 CET 2001 Paolo Molaro <lupus@ximian.com>
9395
9396         * class.h, class.c: add enum_basetype field to MonoClass.
9397         * metadata.h, metadata.c: add mono_metadata_get_constant_index()
9398         to get index in the constant table reated to a field, param or
9399         property.
9400         * reflection.h, reflection.c: handle constructors. Set public-key and
9401         version number of the built assembly to 0.
9402         * row-indexes.h: update from new ECMA spec.
9403
9404 Wed Nov 14 19:26:06 CET 2001 Paolo Molaro <lupus@ximian.com>
9405
9406         * class.h, class.c: add a max_interface_id to MonoClass.
9407         * icall.c: rename my_mono_new_object() to my_mono_new_mono_type()
9408         since it's used to do that. Added mono_type_type_from_obj().
9409         Make GetType() return NULL instead of segfaulting if the type was not
9410         found. Handle simple arrays in assQualifiedName.
9411         * object.h: add a struct to represent an Exception.
9412         * reflection.c: output call convention in method signature.
9413         Add code to support P/Invoke methods and fixed offsets for fields.
9414
9415 Mon Nov 12 12:41:32 CET 2001 Paolo Molaro <lupus@ximian.com>
9416
9417         * decimal.c, decimal.h: mono_double2decimal() get the sign bit from
9418         the value.
9419         * icall.c: use mono_array_addr instead of array->vector: fixes the
9420         reflection image writing.
9421         * reflection.c: init call convention byte to 0 in method signature.
9422         Encode the property signature. Don't output property-related methods
9423         twice. Really process the properties for a type (don't cast a field to
9424         a property, my mom always told me that).
9425         Fix 64 bit issues in pointer alignment in a different and more
9426         readable way.
9427
9428 2001-11-10  Sean MacIsaac  <macisaac@ximian.com>
9429
9430         * loader.h: Removed type class from MonoDefaults, added monotype
9431
9432         * loader.c: Loaded MonoType, removed loading of Type
9433
9434         * icall.c (my_mono_new_object): Now returns a System.MonoType,
9435         and fills in System.Type._impl with a RuntimeTypeHandle rather
9436         than the actual MonoClass *
9437
9438         (ves_icall_type_from_handle): change from type_class to
9439         monotype_class
9440
9441         (ves_icall_System_Runtime_InteropServices_Marshal_ReadIntPtr):
9442         implemented
9443
9444         (ves_icall_System_Runtime_InteropServices_Marshal_PtrToStringAuto):
9445         implemented
9446
9447         (ves_icall_System_Reflection_Assembly_LoadFrom): implemented
9448
9449         (ves_icall_System_Reflection_Assembly_GetType): implemented
9450
9451         (ves_icall_System_MonoType_assQualifiedName): implemented
9452
9453         (ves_icall_System_PAL_OpSys_GetCurrentDirecotry): implemented
9454
9455 2001-11-09  Miguel de Icaza  <miguel@ximian.com>
9456
9457         * assembly.c (mono_assembly_open): Implement a cache for the
9458         assemblies. 
9459
9460         (mono_assembly_close): only destroy the assembly when the last
9461         reference is gone.
9462         
9463 2001-11-09  Dick Porter  <dick@ximian.com>
9464
9465         * Makefile.am (pedump_LDADD): Don't need THREAD_LIBS any more
9466
9467 2001-11-09  Dietmar Maurer  <dietmar@ximian.com>
9468
9469         * class.c (mono_class_metadata_init): bug fix: compute the right slot
9470
9471 Fri Nov 9 15:48:02 CET 2001 Paolo Molaro <lupus@ximian.com>
9472
9473         * icall.c, decimal.h, decimal.c: integrated decimal internalcalls
9474         from Martin Weindel.
9475         * object.h: add mono_string_chars ().
9476
9477 2001-11-07  Miguel de Icaza  <miguel@ximian.com>
9478
9479         * reflection.c (build_compressed_metadata): Eliminates warnings
9480         and uses 64-bit clean code.
9481
9482         * metadata.c (mono_type_hash): Change signature to eliminate warnings.
9483         (mono_type_equal): Change signature to eliminate warnings.
9484
9485 Wed Nov 7 15:40:01 CET 2001 Paolo Molaro <lupus@ximian.com>
9486
9487         * icall.c, loader.c: remove the internalcall array constructors.
9488         Changes to match the new MonoArray structure.
9489         * object.h, object.c: an array object doesn't allocate an extra
9490         vector. Add mono_array_new_full () to create jagged arrays easily.
9491
9492 Mon Nov 5 19:51:06 CET 2001 Paolo Molaro <lupus@ximian.com>
9493
9494         * metadata.h, metadata.c: add mono_metadata_field_info () to
9495         retreive all the info about a field from vairous tables.
9496         * icall.c: implement S.Runtime.CServices::InitializeArray () icall.
9497         * class.h, class.c: augment MonoClassField with more info.
9498         Implemented mono_ldtoken for fields. Implemented ExplicitLayout
9499         policy and load a field's RVA if needed.
9500
9501 2001-11-05  Dietmar Maurer  <dietmar@ximian.com>
9502
9503         * class.c (mono_class_metadata_init): create a trampoline for all
9504         virtual functions instead of actually compiling them.
9505
9506 Fri Nov 2 19:37:51 CET 2001 Paolo Molaro <lupus@ximian.com>
9507
9508         * class.h, class.c: include name in MonoClassField.
9509         * class.c: fix fundamental type of System.Object and System.String.
9510         Set the right fundamental type for SZARRAY, too. Handle TypeSpec
9511         tokens in ldtoken.
9512         * icall.c: remove internalcalls for the Reflection stuff that is now
9513         done in C# code.
9514         * loader.c: mono_field_from_memberref () implementation.
9515         * mono-endian.c: thinko (s/struct/union/g).
9516         * object.c, object.h: make the mono_string_* prototypes actually use
9517         MonoString instead of MonoObject.
9518         * reflection.c, reflection.h: updates for changes in the reflection
9519         code in corlib: we use C structures that map to the actual C# classes.
9520         Handle SZARRAYs when encoding types. Handle locals in methods. Use a
9521         fat method header if needed and use the info from the ILGenerator for
9522         methods. Handle fields in types. Misc fixes.
9523
9524 2001-10-17  Dietmar Maurer  <dietmar@ximian.com>
9525
9526         * class.c (mono_class_metadata_init): bug fix: always allocate
9527         space for static class data
9528
9529 2001-10-25  Dietmar Maurer  <dietmar@ximian.com>
9530
9531         * class.c (mono_compute_relative_numbering): use relative
9532         numbering to support fast runtime type checks.
9533
9534 2001-10-17  Sean MacIsaac  <macisaac@ximian.com>
9535
9536         * class.c (mono_class_create_from_typeref): added debugging output
9537         to print class name when MonoDummy is returned instead of real class
9538
9539 2001-10-15  Dietmar Maurer  <dietmar@ximian.com>
9540
9541         * class.c (mono_class_metadata_init): interface offset table now
9542         contains pointers into the vtable - this is more efficient for the jit
9543
9544 2001-10-12  Dietmar Maurer  <dietmar@ximian.com>
9545
9546         * class.c (mono_class_metadata_init): use a temporary vtable (the
9547         old algorithm only worked for the interpreter, but not for the jit)
9548
9549 2001-10-11  Dietmar Maurer  <dietmar@ximian.com>
9550
9551         * loader.c (method_from_memberref): use mono_class_get to get the
9552         class of an array instead of using System.Array directly.
9553         (mono_get_method): also add MEMBERREF methods to the method cache
9554         which usefull for arrays.
9555
9556 2001-10-10  Dietmar Maurer  <dietmar@ximian.com>
9557
9558         * pedump.c (arch_compile_method): added to compute vtable entry
9559
9560         * metadata.c (mono_metadata_interfaces_from_typedef): also return the
9561         number of interfaces.
9562         
9563         * class.h: merged MonoArrayClass into MonoClass
9564
9565         * class.c (mono_class_create_from_typedef): compute the vtable size and
9566         allocate space to include the vtable inside MonoClass
9567         (mono_class_metadata_init): initialize the vtable
9568
9569 Mon Oct 8 16:12:38 CEST 2001 Paolo Molaro <lupus@ximian.com>
9570
9571         * metadata.c, metadata.h: use MonoArrayType to describe the shape of an array.
9572         Guard against calling bsearch with a NULL pointer (pointed out by Laurent Rioux, smoux).
9573         * image.c: endian fixes by Laurent Rioux.
9574         * object.h, object.c: rename MonoStringObject to MonoString and
9575         MonoArrayObject to MonoArray. Change some function names to conform to
9576         the style mono_<object>_<action>. mono_string_new_utf16 () takes a
9577         guint16* as first argument, so don't use char*.
9578         Provide macros to do the interesting things on arrays in a portable way.
9579         * threads-pthread.c: updates for the API changes and #include <sched.h>
9580         (required for sched_yield()).
9581         * icall.c: updates for the API changes above.
9582         * Makefile.am, mono-endian.c. mono-endian.h: include unaligned read routines for
9583         platforms that need them.
9584
9585 Mon Oct 8 10:43:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
9586
9587         * class.c: set the correct type for all the fundamental
9588         type when loading the class.
9589
9590 2001-10-05  Dick Porter  <dick@ximian.com>
9591
9592         * threads-pthread.c (pthread_mutex_timedlock): Simple
9593         compatibility version for C libraries that lack this call.
9594
9595 Thu Oct 4 19:10:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
9596
9597         * class.c: MonoTypes stored in MonoClass are stored as
9598         fundamental MonoTypes when the class represents a
9599         fundamental type (System.Int32, ...).
9600         The TypeHandle return by ldtoken is a MonoType*.
9601         * icall.c: ves_icall_get_data_chunk () write out all the
9602         PE/COFF stuff. Implement ves_icall_define_method (),
9603         ves_icall_set_method_body (), ves_icall_type_from_handle ().
9604         * image.c: properly skip unknown streams.
9605         * loader.h, loader.c: add type_class to mono_defaults.
9606         * metadata.c, metadata.h: export compute_size () as
9607         mono_metadata_compute_size () with a better interface.
9608         Typo and C&P fixes.
9609         * pedump.c: don't try to print the entry point RVA if there is no entry point.
9610         * reflection.c, reflection.h: many cleanups, fixes, output method
9611         signatures and headers, typedef and typeref info, compress the metadata
9612         tables, output all the heap streams, cli header etc.
9613         * row-indexes.h: typo fixes.
9614
9615 2001-10-04  Dick Porter  <dick@ximian.com>
9616
9617         * object.h: Add a synchronisation mutex struct to MonoObject
9618
9619         * object.c (mono_new_object): Initialise the object
9620         synchronisation mutexes
9621
9622         * icall.c: System.Threading.Monitor internal calls
9623         
9624         * threads-pthread.h:
9625         * threads-pthread.c: System.Threading.Monitor internal calls
9626
9627         * threads-types.h: New file, includes the system-specific thread
9628         structures
9629         
9630         * threads-pthread-types.h:
9631         * threads-pthread-types.c: New files, handle pthread-specific
9632         synchronisation types
9633
9634         * threads-dummy-types.h: 
9635         * threads-dummy-types.c: New files of dummy support for
9636         thread-specific types
9637
9638         * metadata.c:
9639         * image.c:
9640         * pedump.c: include mono-endian.h not endian.h
9641         
9642         * Makefile.am: More threads files.
9643         Name mono-endian.h not endian.h
9644
9645 Tue Oct 2 20:33:48 CEST 2001 Paolo Molaro <lupus@ximian.com>
9646
9647         * Makefile.am, reflection.h, reflection.c: move here the reflection related 
9648         stuff and implement a few more bits.
9649         * icall.c: a field needs to be dereferenced twice. Do not use the same
9650         name for two variables in the same scope.
9651         * image.c, image.h: cleanups.
9652
9653 2001-10-02  Dietmar Maurer  <dietmar@ximian.com>
9654
9655         * class.c (mono_class_metadata_init): bug fix: compute the right size
9656
9657 Mon Oct 1 20:43:57 CEST 2001 Paolo Molaro <lupus@ximian.com>
9658
9659         * icall.c: implemented some of the Reflection internalcalls.
9660         * image.c, image.h: start writing out the PE/COFF image.
9661         * metadata.h, metadata.c: implement mono_metadata_encode_value ()
9662         that does the reverse than decode_blob_size ().
9663         * object.c: use mono_metadata_encode_value (). Move here
9664         temporary implementation of mono_string_to_utf8 ().
9665         * rawbuffer.c: make malloc_map static.
9666
9667 Fri Sep 28 19:26:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
9668
9669         * metadata.c: fix type comparison for arrays.
9670         * loader.h, loader.c: half-assed fix to get more tests work in cygwin.
9671         Added a couple of new classes to monodefaults.
9672         * icall.c: added a couple of Reflection-related internalcalls.
9673         * class.h, class.c: implemented mono_ldtoken () for RuntimeTypeHandles.
9674         Added a byval_arg MonoType to MonoClass.
9675
9676 2001-09-28  Dick Porter  <dick@ximian.com>
9677
9678         * icall.c:
9679         * threads-pthread.h: 
9680         * threads-pthread.c: Implemented internal calls for
9681         LocalDataStoreSlot operations.  Applied mutexes around all shared
9682         data.  Reworked the thread creation and Start() operations to
9683         avoid a race condition.
9684         
9685         * threads-dummy.h:
9686         * threads-dummy.c: Dummy calls for the LocalDataStoreSlot operations
9687
9688 Thu Sep 27 21:45:55 CEST 2001 Paolo Molaro <lupus@ximian.com>
9689
9690         * rawbuffer.c: disable mmap on cygwin since it seems to be broken there.
9691
9692 Thu Sep 27 19:52:11 CEST 2001 Paolo Molaro <lupus@ximian.com>
9693
9694         * class.c, loader.c: warn and return NULL instead of erroring out.
9695         * icall.c: added System.AppDomain::getCurDomain().
9696         * loader.c: we don't need to lookup the typedef again for p/invoke calls.
9697
9698 2001-09-25  Dick Porter  <dick@ximian.com>
9699
9700         * threads-pthread.h:
9701         * threads-pthread.c: Implemented timed thread joining and added
9702         System.Threading.Thread::Join_internal internal call
9703
9704         * icall.c: Added System.Threading.Thread::Join_internal internal call
9705
9706         * threads-dummy.h:
9707         * threads-dummy.c: Dummy calls for System.Thread.Thread::Join_internal
9708
9709 Mon Sep 24 18:56:59 CEST 2001 Paolo Molaro <lupus@ximian.com>
9710
9711         * object.c, object.h: added mono_ldstr (), mono_string_is_interned () and
9712         mono_string_intern () to implement the semantics of the ldstr opcode
9713         and the interning of System.Strings.
9714         * icall.c: provide hooks to make String::IsIntern and String::Intern
9715         internalcalls.
9716
9717 2001-09-23  Dick Porter  <dick@ximian.com>
9718
9719         * threads-dummy.c: 
9720         * threads-dummy.h: New files of dummy threading routines
9721
9722         * Makefile.am (THREAD_SOURCE): Arrange to compile different thread
9723         support code based on system specifics
9724
9725         Rename PTHREAD_LIBS to THREAD_LIBS
9726         
9727 2001-09-23  Dick Porter  <dick@ximian.com>
9728
9729         * threads-pthread.c: Implement the System.Threading.Thread::Sleep,
9730         Schedule (called when asked to Sleep for 0 ms) and CurrentThread
9731         internal calls.
9732         (mono_thread_init): Set up a Thread object instance to return when
9733         the main thread calls Thread.CurrentThread
9734         (mono_thread_cleanup): Wait for all subthreads to exit
9735
9736         * icall.c: New internal calls for System.Threading.Thread::Sleep
9737         (including Schedule) and CurrentThread
9738
9739         * threads.h: New file, to insulate thread-specific stuff from the
9740         rest of the code
9741
9742 2001-09-21  Dick Porter  <dick@ximian.com>
9743
9744         * threads-pthread.h: 
9745         * threads-pthread.c: New file, for handling pthreads-style
9746         threading support.  Start() now starts a new thread and executes
9747         the ThreadStart delegate instance.
9748
9749         * icall.c: Added the internalcall for
9750         System.Threading.Thread::Start_internal
9751
9752         * Makefile.am: Added new files, and PTHREADS_LIBS to the link line
9753
9754 Thu Sep 20 19:37:39 CEST 2001 Paolo Molaro <lupus@ximian.com>
9755
9756         * loader.c: work around the different signatures for delegates
9757         constructors csc generates in compiled code vs the ones compiled in mscorlib.
9758
9759 Tue Sep 18 13:16:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
9760
9761         * class.h, class.c: add mono_class_get_field_from_name ().
9762         * *: Fix C comments and other ANSI C issues.
9763
9764 Mon Sep 10 20:21:34 CEST 2001 Paolo Molaro <lupus@ximian.com>
9765
9766         * endian.h, assembly.c: fix some endianness issues.
9767
9768 Fri Sep 7 18:40:40 CEST 2001 Paolo Molaro <lupus@ximian.com>
9769
9770         * loader.h, load.c: add delegate_class to mono_defaults.
9771         Handle runtime provided methods in mono_get_method ().
9772
9773 2001-08-29  Dietmar Maurer  <dietmar@ximian.com>
9774
9775         * loader.c (mono_get_method): use pinvoke for internal call
9776
9777         * icall.c: use pinvoke for internal call
9778
9779         * loader.c (method_from_memberref): set the method name
9780
9781 Wed Aug 29 12:43:41 CEST 2001 Paolo Molaro <lupus@ximian.com>
9782
9783         * metadata.c: help the compiler generate better code for
9784         mono_class_from_mono_type ().
9785
9786 2001-08-28  Dietmar Maurer  <dietmar@ximian.com>
9787
9788         * class.c (mono_class_metadata_init): delayed computing of the
9789         class size to mono_class_metadata_init ()
9790
9791 Tue Aug 28 15:47:15 CEST 2001 Paolo Molaro <lupus@ximian.com>
9792
9793         * class.c, class.h: add an interfaces member to MonoClass.
9794         * image.c, image.h: add assembly_name field to MonoImage
9795         from the assembly table.
9796         * metadata.c, metadata.h: add mono_metadata_interfaces_from_typedef ().
9797
9798 Mon Aug 27 20:12:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
9799
9800         * class.c: Handle Array in mono_class_from_mono_type ().
9801         * metadata.c, pedump.c: some endian fixes.
9802
9803 Mon Aug 27 15:23:23 CEST 2001 Paolo Molaro <lupus@ximian.com>
9804
9805         * class.c, loader.c, loader.h: More types handled in mono_class_from_mono_type ().
9806         * metadata.c: fix small problem introduced with the latest commit.
9807
9808 Mon Aug 27 12:17:17 CEST 2001 Paolo Molaro <lupus@ximian.com>
9809
9810         * loader.c, metadata.c, metadata.h: Export mono_metadata_type_equal().
9811         We don't need a MonoMetadata pointer anymore to compare signatures in
9812         mono_metadata_signature_equal (), update callers.
9813         Reduced memory usage an number of allocations for MonoMethodHeader and
9814         MonoMethodSignature.
9815
9816 Sun Aug 26 23:03:09 CEST 2001 Paolo Molaro <lupus@ximian.com>
9817
9818         * metadata.c: added compare for szarray.
9819
9820 Sun Aug 26 11:34:24 CEST 2001 Paolo Molaro <lupus@ximian.com>
9821
9822         * class.h, class.c, loader.h, loader.c: export mono_class_from_mono_type ()
9823         and add a couple more types to it and mono_defaults. Give an hint on
9824         classes that need implementing in our corlib and are referenced
9825         in mscorlib.
9826
9827 Sat Aug 25 12:52:54 CEST 2001 Paolo Molaro <lupus@ximian.com>
9828
9829         * class.h, class.c: keep track if a class is also an Enum.
9830         * loader.c: Implement a couple more types for use in libffi
9831         marshalling. Gives better diagnostics when failing to dlopen
9832         a library. Set method->klass for P/Invoke methods, too.
9833
9834 Fri Aug 24 19:30:25 CEST 2001 Paolo Molaro <lupus@ximian.com>
9835
9836         * class.c, class.h: add a MonoType this_arg to MonoClass that
9837         represents a pointer to an object of the class' type that
9838         can be used by the interpreter and later the type cache.
9839         Add best guess alignment info for valuetype objects.
9840
9841 Fri Aug 24 15:50:31 CEST 2001 Paolo Molaro <lupus@ximian.com>
9842
9843         * metadata.h, metadata.c, class.h, class.c: squeezed MonoParam
9844         into MonoType: one less level of indirection and allocation and
9845         simplifies quite a bit of code. Added cache for MonoTypes that are
9846         used frequently, so that we don't need to allocate them all the time.
9847
9848 2001-08-24  Dietmar Maurer  <dietmar@ximian.com>
9849
9850         * class.c (mono_class_create_from_typedef): System.Enum is also a
9851         value type, although it does not derive from System.ValueType
9852         (maybe a bug in the ms compiler?)
9853
9854         * metadata.c (mono_type_size): return the right size for value types
9855
9856         * loader.c (mono_get_method): only initialize method header if not abstract
9857
9858         * class.c (mono_class_from_mono_type): use mono_default values. 
9859
9860 2001-08-23  Dietmar Maurer  <dietmar@ximian.com>
9861
9862         * *: use MonoClass pointers instead of <type_tokens>
9863         
9864         * class.h: new flag: metadata_inited.
9865
9866         * class.c (mono_class_metadata_init): impl.
9867         (mono_class_instance_size): impl.
9868         (mono_class_data_size): impl.
9869
9870 Wed Aug 22 16:27:30 CEST 2001 Paolo Molaro <lupus@ximian.com>
9871
9872         * metadata.c, loader.h, loader.c, image.h, image.c, class.h, class.c:
9873         MonoClass now has the name and name_space fields. 
9874         MonoMethod has a pointer to its MonoClass, instead of MonoImage.
9875         mono_get_method () takes and optional MonoClass as argument.
9876         Removed mono_typedef_from_name() and added mono_class_token_from_name()
9877         instead that takes advantage of a map from class names to typedef
9878         tokens in MonoImage.
9879
9880 Tue Aug 21 18:54:58 CEST 2001 Paolo Molaro <lupus@ximian.com>
9881
9882         * metadata.c: zero is not a valid alignment boundary.
9883         Merge MONO_TYPE_VOID in default decoding code.
9884
9885 2001-08-21  Dietmar Maurer  <dietmar@ximian.com>
9886
9887         * image.h: merged MonoMetadata into MonoImage
9888
9889         * class.h: cleanup of MonoArrayClass, use a MonoClass pointer to
9890         identify the type of elements.
9891
9892 Mon Aug 20 19:39:00 CEST 2001 Paolo Molaro <lupus@ximian.com>
9893
9894         * blob.h: fix MONO_TYPE_TYPEDBYREF value.
9895         * cil-coff.h: split MonoMSDOSHeader and add size info.
9896         * image.c: add some consistency checks.
9897         * metadata.c: fix row size computation: one programmer
9898         error and one LAMESPEC. Handle MONO_TYPE_TYPEDBYREF.
9899         add explanation for the locator routine.
9900         Fix decoding of size in method header.
9901         
9902 2001-08-20  Miguel de Icaza  <miguel@ximian.com>
9903
9904         * assembly.c    (g_concat_dir_and_file): Use _S for string concat.
9905         (g_concat_dir_and_file): Bring g_concat_dir_and_file
9906         function from gnome-libs.  This uses the right path separator
9907         based on the OS, and also works around a bug in some systems where
9908         a double slash is not allowed. 
9909         (default_assembly_name_resolver): Use g_concat_dir_and_file
9910         (mono_assembly_open): ditto.
9911
9912 2001-08-20  Dietmar Maurer  <dietmar@ximian.com>
9913
9914         * metadata.c (mono_metadata_signature_equal): impl.
9915
9916         * *: void is now a realy MonoType (instead of using NULL)
9917         
9918         * metadata.c (do_mono_metadata_parse_type): use
9919         mono_metadata_parse_type to parse void value.
9920
9921 Sat Aug 18 12:51:28 CEST 2001 Paolo Molaro <lupus@ximian.com>
9922
9923         * metadata.c, metadata.h: in the signature and method header store
9924         only the space required for holding the loca vars and incoming arguments.
9925
9926 2001-08-15  Dietmar Maurer  <dietmar@ximian.com>
9927
9928         * metadata.c (do_mono_metadata_parse_type): treat void like any
9929         other type (instead of assigning NULL);
9930
9931 2001-08-14  Dietmar Maurer  <dietmar@ximian.com>
9932
9933         * metadata.c (mono_metadata_parse_mh): fixxed pinned/byref value
9934
9935 2001-08-09  Dietmar Maurer  <dietmar@ximian.com>
9936
9937         * image.c (do_mono_image_open): added a cache for arrays.
9938
9939 Sat Aug 4 12:46:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
9940
9941         * metadata.h, metadata.c: add mono_metadata_decode_row_col () to
9942         decode a single column from a row in a metadata table and changes
9943         to take advantage of it in the typedef locator (gives a nice speed up).
9944         Store offset info for function params.
9945
9946 2001-08-02  Dietmar Maurer  <dietmar@ximian.com>
9947
9948         * image.h (MONO_IMAGE_IS_CORLIB): removed 
9949
9950 Wed Aug 1 22:54:08 CEST 2001 Paolo Molaro <lupus@ximian.com>
9951
9952         * assembly.c: how could mono_assembly_close () had ever worked?
9953         * metadata.c, metadata.h: provide offset info for local vars.
9954         Implement mono_type_size () to take care of alignment as well
9955         as size (it was mono_field_type_size in cli/class.c before).
9956
9957 2001-08-01  Dietmar Maurer  <dietmar@ximian.com>
9958
9959         * image.h (MONO_IMAGE_IS_CORLIB): new macro to check root image
9960
9961         * assembly.h (CORLIB_NAME): set to corlib.dll
9962
9963         * assembly.c (mono_assembly_open): replaced strcmp() with !strcmp()
9964
9965 Tue Jul 31 17:54:02 CEST 2001 Paolo Molaro <lupus@ximian.com>
9966
9967         * metadata.h, metadata.c, Makefile.am, private.h, assembly.c, blob.h,
9968         cil-coff.h, image.c, image.h, pedump.c, rawbuffer.c, rawbuffer.h, row-indexes.h,
9969         tokentype.h: massive namespace cleanup.
9970
9971 Mon Jul 30 20:11:01 CEST 2001 Paolo Molaro <lupus@ximian.com>
9972
9973         * metadata.h, metadata.c: decode exception clauses when parsing method header.
9974
9975 2001-07-27  Dietmar Maurer  <dietmar@ximian.com>
9976
9977         * metadata.c (mono_metadata_free_type): added check for type !=
9978         NULL (void) before calling mono_metadata_free_type()
9979
9980 Thu Jul 26 19:11:19 CEST 2001 Paolo Molaro <lupus@ximian.com>
9981
9982         * metadata.h, row_indexes.h: added header with enumerations to use
9983         to index in the columns from tables in metadata and to decode coded
9984         tokens: we should start using this instead of embedding magic numbers
9985         all over the code.
9986
9987 Thu Jul 26 13:03:27 CEST 2001 Paolo Molaro <lupus@ximian.com>
9988
9989         * assembly.c, cil-coff.h, image.c, image.h, pedump.c, typedef.c:
9990         Move metadata_t info from cli_image_info_t to MonoImage, where
9991         it's easily accessible. Changed all the uses accordingly.
9992         Added the method and class caches to MonoImage.
9993         * metadata.c, metadata.h: Changed mono_metadata_decode_blob_size ()
9994         and mono_metadata_decode_value () signature to be more consistent
9995         with the other parse functions (and simplify code). Taken advantage
9996         of zero-length array allocation with GCC. Removed reduntant (and
9997         wrong) MonoFieldType struct and use MonoParam instead. Changed
9998         mono_metadata_parse_field_type () to use common code for parsing.
9999         Added mono_metadata_typedef_from_field () and
10000         mono_metadata_typedef_from_method () to lookup a typedef index from a
10001         field or method token.
10002         Pack the MonoRetType structure more tightly (fits in 8 bytes now).
10003
10004 2001-07-23  Miguel de Icaza  <miguel@ximian.com>
10005
10006         * metadata.c (mono_metadata_parse_field_type): Implement. 
10007         (do_mono_metadata_parse_type): Split engine from
10008         mono_metadata_parse_type, so that we can create smaller structures
10009         for things that just have one pointer to the MonoType (look at
10010         the MonoFieldType)
10011
10012 2001-07-20  Miguel de Icaza  <miguel@ximian.com>
10013
10014         * metadata.c (mono_metadata_parse_mh): Correct the implementation,
10015         as Jan Gray found out, it is incorrect. 
10016
10017 2001-07-18  Miguel de Icaza  <miguel@ximian.com>
10018
10019         * assembly.c: Implement asssembly loading.  This loads an image
10020         and loads all the referenced assemblies.  Come to think of it, we
10021         could always do lazy loading of the assemblies. 
10022
10023         * image.c (mono_image_open): Keep loaded images in a hashtable.
10024
10025         * image.h (MonoImage): Add reference count.
10026
10027 2001-07-17  Miguel de Icaza  <miguel@ximian.com>
10028
10029         * assembly.c (mono_assembly_open): Keep track of the file name in
10030         case the assembly has no ASSEMBLY table.
10031
10032         * metadata.h: Fixed Paolo's quick hack.  Put the documnentation
10033         from get.c here.
10034
10035 Sun Jul 15 19:39:06 CEST 2001 Paolo Molaro <lupus@ximian.com>
10036
10037         * metadata.c, metadata.h: decode local vars in method header
10038         parse function. Change callers accordingly.
10039
10040 Sun Jul 15 17:40:47 CEST 2001 Paolo Molaro <lupus@ximian.com>
10041
10042         * metadata.h, cil-coff.h: protect against multiple inclusion.
10043         Added some new structures to hold information decoded from metadata:
10044         MonoType, MonoParam, MonoArray, MonoMethod, MonoMethodSignature
10045         and relevant decoding/free functions.
10046         * metadata.c: implement decoding functions. Add warning for out of bounds
10047         index in mono_metadata_locate(). Implement mono_get_method () to retreive
10048         all the info about a method signature and invocation. Remove check on
10049         uninitialized local var in parse_mh() and fix memory leak.
10050
10051 2001-07-12  Miguel de Icaza  <miguel@ximian.com>
10052
10053         * metadata.h: More macros.
10054
10055         * tokentype.h: New file.
10056
10057 Fri Jul  6 11:30:53 CEST 2001 Paolo Molaro <lupus@ximian.com>
10058
10059         * assembly.c: added a consistency check and initialize
10060         some structures with g_new0().
10061         * metadata.c: fixed a couple more bugs in table size computation
10062         and add other checks for out-of bound access to metadata.
10063
10064 Thu Jul  5 22:34:21 CEST 2001 Paolo Molaro <lupus@ximian.com>
10065
10066         * metatada.c: fix bugs computing table sizes. Spew a
10067         warning when index in string heap is out of bounds.
10068
10069 2001-07-04  Miguel de Icaza  <miguel@ximian.com>
10070
10071         * metadata.h: Add a couple of macros to manipulate tokens. 
10072
10073 Tue Jul  3 18:33:32 CEST 2001 Paolo Molaro <lupus@ximian.com>
10074
10075         * assembly.c: g_free(ii->cli_sections) (and avoid double free of
10076         cli_section_tables).
10077
10078 2001-07-01  Miguel de Icaza  <miguel@ximian.com>
10079
10080         * metadata.c (mono_metadata_user_string): New function, provides
10081         access to the UserString heap. 
10082
10083 2001-06-27  Miguel de Icaza  <miguel@ximian.com>
10084
10085         * metadata.c: Add inline documentation.
10086
10087 2001-06-26  Miguel de Icaza  <miguel@ximian.com>
10088
10089         * propertyattr.h, paramattr.h, methodsem.h, methodattr.h: New
10090         files. 
10091
10092 2001-06-22  Miguel de Icaza  <miguel@ximian.com>
10093
10094         * typeattr.h: New file, TypeAttribute flags. 
10095
10096 2001-06-21  Miguel de Icaza  <miguel@ximian.com>
10097
10098         * mono/metadata/assembly.c (mono_assembly_ensure_section_idx,
10099         mono_assembly_ensure_section): Section loading code.
10100         (load_section_tables): Load the sections.
10101
10102         * mono/metadata/metadata.c (mono_metadata_locate_token,
10103         mono_metadata_locate): Functions to locate the information
10104         definition given a token or a table and an index.
10105         (mono_metadata_compute_table_bases): New.
10106         (compute_size): New function to compute the sizes of the various
10107         tables.
10108
10109         * mono/metadata/metadata.h: Finish listing the different index
10110         types. 
10111
10112         * mono/metadata/pedump.c: Improve to dump new information.
10113
10114 2001-06-19  Miguel de Icaza  <miguel@ximian.com>
10115
10116         * mono/metadata/metadata.c: Entered all the tables matching
10117         Beta2. 
10118
10119         * mono/metadata/assembly.c (load_metadata_ptrs): Fix for Beta2
10120
10121
10122
10123
10124
10125
10126
10127