
''' <summary>
''' A comparer that tests for reference equality.
''' </summary>
''' <remarks></remarks>
Public Class ReferenceEqualityComparer
    Inherits EqualityComparer(Of Object)

    Public Overloads Overrides Function Equals(x As Object, y As Object) As Boolean
        Return Object.ReferenceEquals(x, y)
    End Function

    Public Overloads Overrides Function GetHashCode(obj As Object) As Integer
        If (obj Is Nothing) Then _
            Return 0
        Return obj.GetHashCode()
    End Function

End Class