dimanche 28 juin 2015

I'm trying to compile a relatively big legacy c++ project in visual-studio-2013 using /clr flag. The project generates a dll.

I get the following run-time exception:

Type '<Module>' from assembly ... contains more methods than the current implementation allows

I must add that this happens in Debug configuration only (Release - works). Also, the project heavily uses templates and macros, which (I suppose) contribute to the large amount of generated methods...

There is little to no documentation regarding this problem. What I know from searching the net (don't know if it's accurate) is:

There is a limit of ~65K methods in a clr dll. All methods of all native classes go into some special <Module>, so it poses a global limit.

One suggestion was to split the project, but that's not very trivial, due to inter-class-dependencies. I suppose this is doable...

Any help would be appreciated.

Aucun commentaire:

Enregistrer un commentaire