[Mono-dev] generic constraints support for corcompare
atsushi at ximian.com
Wed Oct 5 15:00:18 EDT 2005
>> The attached patch makes corcompare stuff to differentiate generic
>> constraints (i.e. "where") on both types and method parameters.
> this is really cool :-)
>> (To see the expected results you will have to create your own
>> It should just work, but am wondering how those diffs should be
>> shown in the class status pages. Currently this patch just puts
>> mysterious "missing" mark on types.
>> Any good ideas? Or if anyone hacks a fix it would be awesome.
> Well, first of all, we need to include the type parameter names in the
> type names, ie. use "ICollection[T]" instead of "ICollection`1". Btw. I
> just realized that the display of generic types is currently broken
Well, for some cases base types are bound (i.e. they are not T but
concrete System.Blah) where type.ToString() shows "Foo`1[Bar]".
For generic constraints I added, it does not seem showing `1 so I
think it's fine (it would depend on what comes after "where" though).
For the "broken" ToString(), I've filed a bug a few days ago:
> After that, maybe we can make things look like this:
> + K : IEnumerable[V]
> X V : class
Ok, it looks cool. I'd take this way.
More information about the Mono-devel-list