Hey,

On Tue, May 18, 2010 at 6:34 AM, Timwi <[email protected]> wrote:
> I have an assembly containing a type that implements IEnumerable<int>.
> The property TypeDefinition.Interfaces correctly lists this interface.
> Now I retrieve the type IEnumerable<T> (or IEnumerable`1) using
> GetElementType().
>
> I would have expected that element type to have one generic parameter.
> However, the GenericParameters property returns an empty collection.
>
> Is this a bug, or did I misunderstand something?

Could be a bit of both. At the metadata level, Cecil has no idea of
the generic arity of a TypeReference. Most of the time, it infers it
from its usage. Could you provide a small test case?

-- 
Jb Evain  <[email protected]>

-- 
--
mono-cecil

Reply via email to