Current compare function is not "Strict Weak Ordering" since it returns true when both arguments are equal, should be false.
Description
The "Strict Weak Ordering" criteria is necessary because some sort implementations will end in a dead-loop without it.
Additional information about the PR answering following questions:
- Is this a new feature or a bug fix? BUG
- More detail if necessary to describe all commits in pull request.
- Why these changes are necessary. To guarantee that the code runs on any compiler
- Potential impact on specific hardware, software or backends. None
- New functions and their functionality. None
- Can this PR be backported to older versions? Yes
- Future changes not implemented in this PR. None
Fixes: #3378
Changes to Users
None
Checklist
- Rebased on latest master
- Code compiles
- Tests pass
- Functions added to unified API
- Functions documented