[Mono-dev] Patch for System.ComponentModel.TypeDescriptor

Vladimir Krasnov vladimirk at mainsoft.com
Thu Jan 3 06:32:39 EST 2008

Hi Ivan,

You are right, I've reverted the "Hashtable patch" and everything works
fine. TestGetProperties in TypeDescriptorTests is ok also.
Look at attached patch.


-----Original Message-----
From: mono-devel-list-bounces at lists.ximian.com
[mailto:mono-devel-list-bounces at lists.ximian.com] On Behalf Of Ivan N.
Sent: Thursday, January 03, 2008 2:24 AM
To: mono-devel-list at lists.ximian.com
Subject: Re: [Mono-dev] Patch for System.ComponentModel.TypeDescriptor

Vladimir Krasnov wrote:
> Hello,
> Please review and approve attached patch for
> TypeDescriptor.GetProperties() method. This fixes the order of 
> properties in the returning collection which is important for 
> System.Web data bound controls.

You can get rid off the Hashtable used in TypeInfo.GetProperties. I
introduced it because at some point Type.GetProperties used to return
two AnotherProperty PropertyInfos for typeof(B) in the following case:

	class A
		public string AnotherProperty {

	class B : A
		public new string AnotherProperty {

It seems to no longer be the case (back then I did not test the
Type.GetProperties behavior on msnet and assumed bug in TypeDescriptor),
but you should test to make sure. You can check test #G2 in
TestGetProperties in TypeDescriptorTests.

Ivan N. Zlatev

Web: http://www.i-nZ.net
"It's all some kind of whacked out conspiracy."
Mono-devel-list mailing list
Mono-devel-list at lists.ximian.com
-------------- next part --------------
A non-text attachment was scrubbed...
Name: TypeDescriptor.cs.patch
Type: application/octet-stream
Size: 1112 bytes
Desc: TypeDescriptor.cs.patch
Url : http://lists.ximian.com/pipermail/mono-devel-list/attachments/20080103/da151eb3/attachment.obj 

More information about the Mono-devel-list mailing list