Skip to content

openpgp: Make KeyHandle::partial_cmp transitive.

Justus Winter requested to merge justus/merge-me into main
  • Previously, KeyHandle::partial_cmp tried to sort aliasing handles together. However, this made the function not transitive, which is required by implementations of PartialOrd.

    • Fix this by simply comparing the byte representations, and computing aliasing in KeyHandle::aliases.

    • Note: This makes PartialOrd (and PartialEq) total, but we still don't implement Ord (and Eq) to prevent naive comparisons.

Merge request reports