I'll look into switching to a caching resolver. Thanks for the pointer, i'll
let you know how it goes

On Tue, Jul 12, 2011 at 10:40 PM, Jb Evain <[email protected]> wrote:

> On Tue, Jul 12, 2011 at 2:36 PM, Hendry Luk <[email protected]> wrote:
> > I just tried but it seems that the scopes are not equal either.
> > I.e.:
> >
> > Equals(typeDef.Scope, typeDef.Module.Import(type).Resolve().Scope)
>
> Same issue as before, if you're not making sure you use a caching
> resolver for all your assemblies, you'll load the same assemblies
> multiple times, and then you won't be able to compare using object
> equality.
>
> So if you don't do that, you need to get the scope, check what it is
> (could be a ModuleDefinition, a ModuleReference, or an
> AssemblyNameReference), and find a way to compare those by name.
>
> Jb
>
> --
> --
> mono-cecil

-- 
--
mono-cecil

Reply via email to