Result of calling IEquatable.Equals(T obj) when this == null and obj == null?

前端 未结 7 582
鱼传尺愫
鱼传尺愫 2021-01-12 07:05

What should IEquatable.Equals(T obj) do when this == null and obj == null?

1) This code is generated

7条回答
  •  庸人自扰
    2021-01-12 07:52

    If this==null you will get a runtime exception calling Equals() on that object.

提交回复
热议问题