【问题标题】:How to find source file of .net Built in functions like WriteLine()如何查找 .net 的源文件 内置函数,如 WriteLine()
【发布时间】:2020-07-26 11:28:49
【问题描述】:

我正在尝试查看一些内置 c# 函数的源代码并尝试探索 System.Console 类等。我通过将鼠标悬停在 ReadLine() 等内置函数上来使用 ctrl+click。在使用 ctrl+click 时,它会将我重定向到 System.Console 元数据页面 -> 我可以在其中找到只有声明可用

    // Summary:
    //     Writes the specified string value, followed by the current line terminator, to
    //     the standard output stream.
public static void WriteLine(string value);

在上述情况下,该函数仅被声明但找不到任何定义。那么,有人可以帮忙吗?有什么办法可以查到c#内置函数的源码定义吗?

【问题讨论】:

标签: c# .net .net-core


【解决方案1】:

如果没有提供源代码,您可以使用dnSpy

【讨论】:

    猜你喜欢
    • 2012-01-26
    • 2014-04-13
    • 2020-01-31
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2021-10-05
    • 2022-01-05
    相关资源
    最近更新 更多