Checks if two distances are equivalent. x and y can be distances (InfinitySparseMatrix, BlockedInfinitySparseMatrix, or DenseMatrix), or they can be optmatch objects.
      Source: R/optmatchS3.R
      optmatch_same_distance.RdTo save space, optmatch objects merely store a hash of the distance
matrix instead of the original object. Any distance objects are hashed before
comparison.