Domanda

If i reference unused assembly using the /r flag in the command prompt the csc will ignore it.

so what if i reference unused assemblies via the IDE will it show the same behavior ?

and what if i am using other c# compilers other than Microsoft's csc ?

È stato utile?

Soluzione

Mono's mcs compiler will not include references unless they're actually used in your app.

And even if they were, the referenced assemblies would only be loaded when used in your app. But since they're not, they'd just waste a few bytes in the assembly.

Autorizzato sotto: CC-BY-SA insieme a attribuzione
Non affiliato a StackOverflow
scroll top