开发者

Where is the output file of microsoft ILGenerator?

开发者 https://www.devze.com 2023-02-12 06:53 出处:网络
I\'ve used Microsoft ILGenerator an开发者_JAVA百科d its Emit member. I want to know where I can find the output il file which is generated by it.The generated IL is not saved to disk automatically. Yo

I've used Microsoft ILGenerator an开发者_JAVA百科d its Emit member. I want to know where I can find the output il file which is generated by it.


The generated IL is not saved to disk automatically. You need to first ensure that your AssemblyBuilder is created (through AppDomain.DefineDynamicAssembly()) with an AssemblyBuilderAccess of Save or RunAndSave.

Once you have generated all your IL, you can then use the Save() method on the AssemblyBuilder to save the generated assembly to disk.

0

精彩评论

暂无评论...
验证码 换一张
取 消