2003-10-15 Martin Baulig <martin@ximian.com>
authorMartin Baulig <martin@novell.com>
Tue, 14 Oct 2003 22:28:40 +0000 (22:28 -0000)
committerMartin Baulig <martin@novell.com>
Tue, 14 Oct 2003 22:28:40 +0000 (22:28 -0000)
commit5deacd7bfab90873f2fe83582e31fc982c42775e
treec46902aad2985c74b9f28221c1c7a6948b914801
parent3a594a78deab4ca078cbc6cf155929f83675dc54
2003-10-15  Martin Baulig  <martin@ximian.com>

* class.c (mono_class_from_gen_param): Renamed to
mono_class_from_generic_parameter() and moved most of the
functionality from mono_reflection_define_generic_parameter()
here; ie. we create a "real" class here.
(mono_class_from_mono_type): Only allow MONO_TYPE_VAR and
MONO_TYPE_MVAR if mono_class_from_generic_parameter() has
previously been called.

* class.h (MonoGenericParam): Moved the declaration of this struct
here from metadata.h and added `MonoMethod *method'.

* icall.c (ves_icall_MonoType_get_DeclaringMethod): New
interncall.

* loader.c (mono_get_method_from_token): If we have any generic
parameters, call mono_metadata_load_generic_params() to read them
from the MONO_TABLE_GENERICPAR.

* metadata.c (mono_metadata_load_generic_params): Added
`MonoMethod *method' argument which is used MONO_TYPE_MVAR.

* metadata.h (MonoMethodSignature): Replaced
`MonoGenericInst *geninst' with `guint16 generic_param_count'.
(MonoMethodHeader): Added `MonoGenericParam *gen_params'.

* reflection.c (mono_reflection_define_generic_parameter): Moved
most of the functionality into the new
mono_class_from_generic_parameter(); set the `method' field if
we're a method parameter.

svn path=/trunk/mono/; revision=19051
mono/metadata/ChangeLog
mono/metadata/class.c
mono/metadata/class.h
mono/metadata/icall.c
mono/metadata/loader.c
mono/metadata/loader.h
mono/metadata/metadata.c
mono/metadata/metadata.h
mono/metadata/reflection.c
mono/metadata/reflection.h