blsttc 8.0.2

Pairing threshold cryptography
Documentation
1
2
3
4
5
6
7
8
9
10
use std::cmp::Ordering;

use group::prime::PrimeCurveAffine;

/// Compares two curve elements and returns their `Ordering`.
pub fn cmp_affine<G: PrimeCurveAffine>(x: &G, y: &G) -> Ordering {
    let xc = x.to_bytes();
    let yc = y.to_bytes();
    xc.as_ref().cmp(yc.as_ref())
}