Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
为什么在 C# 中 throw null 不是编译器警告?
我看到了一些代码,其中有一个throw null;。这会导致一个新NullReferenceException 的被抛出。
throw null;
NullReferenceException
为什么编译器不会用警告标记这个?