On Feb 27, 2012, at 7:43 PM, Remy Blok wrote: > The exception message is also not much of an help, since it points you > in the wrong direction. I'm wondering if the "new ParameterDefinition > (viewModelType)" should not have thrown an exception explaining you > need a TypeReference in stead of a TypeDefinition, in case of the type > living in another Assembly. Just a thought...
Yeah. That's the unfortunate consequence of a old design decision: metadata is allowed to not be connected to a module until they are attached to one. As such the API makes no immediate check. It would be cool to solve eventually by providing factory methods to make sure all pieces of metadata are always connected to a module. Jb -- -- mono-cecil
