如何使用 csc(C# 编译器)或 dmcs(单 C# 编译器)生成 IL 源代码? [英] How to generate IL source code with csc (C# compiler) or dmcs (mono C# compiler)?

查看:24
本文介绍了如何使用 csc(C# 编译器)或 dmcs(单 C# 编译器)生成 IL 源代码?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

gcc has an option of -s to generate assembly source code. Does csc (MS C# compiler) or dmcs (mono C# compiler) have equivalence? I mean do those compilers provide an option to generate IL source code that can be read not the execution binary?

解决方案

It's very easy to get to the IL: just use ildasm. The /text option prints the result to the console, which you can divert to a file.

这篇关于如何使用 csc(C# 编译器)或 dmcs(单 C# 编译器)生成 IL 源代码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆