-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Description
Describe the issue or suggestion
Vector's inequality operator documentation appears incorrect: "Returns a value that indicates whether any single pair of elements in the specified vectors is equal." (emphasis mine)
Rather, we would expect: "Returns a value that indicates whether any single pair of elements in the specified vectors is unequal."
We can base this expectation on both common sense (inequality means there is something unequal between the operands) and the corresponding equality operator documentation: "Returns a value that indicates whether each pair of elements in two specified vectors are equal."
If == indicates whether each pair is equal, then != should indicate whether the opposite is true, i.e. whether there is any pair that is unequal.
My assumption here is that only the documentation of != is incorrect, and not its behavior, although I have not tested this.
The impact of the current documentation could be that developers opt for !(a == b) just to make sure they get the intended behavior.
Side note
The equality operator documentation could be improved when it comes to grammar: "whether each pair [...] are equal" should be "whether each pair [...] is equal".