dotnet / dotnet/dotnet-api-docs

ValueTuple generic types do not specify rules for comparison

Open
#3,590 0 comments 0 reactions 0 assignees View on GitHub
area-System.Runtime Pri3 untriaged
Dominant language
C#
Stars
949
Forks
1.7k
Avg merge
3d 27m
Merged PRs (30d)
49

Description

# ValueTuple generic types do not specify rules for comparison

In addition to explicit interface implementations that support a custom comparison method, each generic `ValueTuple` type has a `CompareTo` method that compares the instance with a tuple of that type. However, the rules for comparison are not specified. Since they are specified in the case of the generic Tuple types, they should be documented for ValueTuple as well, so that there is parity between Tuple and ValueTuple generic types.

See also dotnet/docs#2956, which noted that the documentation for `ValueTuple.CompareTo(ValueTuple)`, the comparison method for a 0-tuple, was incorrect.

/cc @int19h

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.