mirror of
https://github.com/saymrwulf/curve25519-dalek-source.git
synced 2026-09-04 20:24:10 +00:00
Remove BASEPOINT_ORDER_MINUS_* constants
These were originally added in 32da4c7d50
to implement Scalar negation in terms of multiply-add.
But we have a full implementation of scalar arithmetic now, so it's not
necessary to keep the constants around.
This commit is contained in:
parent
690637e368
commit
d3a8ee0d7b
2 changed files with 0 additions and 26 deletions
|
|
@ -71,26 +71,6 @@ pub const BASEPOINT_ORDER: Scalar = Scalar{
|
|||
],
|
||||
};
|
||||
|
||||
/// `BASEPOINT_ORDER_MINUS_1` is the order of base point minus one, i.e. `l-1`, in little-endian bytes.
|
||||
pub const BASEPOINT_ORDER_MINUS_1: Scalar = Scalar{
|
||||
bytes: [
|
||||
0xec, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58,
|
||||
0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
|
||||
],
|
||||
};
|
||||
|
||||
/// `BASEPOINT_ORDER_MINUS_2` is the order of base point minus two, i.e. `l-2`, in little-endian bytes.
|
||||
pub const BASEPOINT_ORDER_MINUS_2: Scalar = Scalar{
|
||||
bytes: [
|
||||
0xeb, 0xd3, 0xf5, 0x5c, 0x1a, 0x63, 0x12, 0x58,
|
||||
0xd6, 0x9c, 0xf7, 0xa2, 0xde, 0xf9, 0xde, 0x14,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00,
|
||||
0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x10,
|
||||
],
|
||||
};
|
||||
|
||||
// Precomputed basepoint table is generated into a file by build.rs
|
||||
|
||||
#[cfg(feature="precomputed_tables")]
|
||||
|
|
|
|||
|
|
@ -790,12 +790,6 @@ mod test {
|
|||
assert_eq!(should_be_two, two);
|
||||
}
|
||||
|
||||
#[test]
|
||||
fn impl_sub() {
|
||||
let should_be_one = &constants::BASEPOINT_ORDER - &constants::BASEPOINT_ORDER_MINUS_1;
|
||||
assert_eq!(should_be_one, Scalar::one());
|
||||
}
|
||||
|
||||
#[allow(non_snake_case)]
|
||||
#[test]
|
||||
fn impl_mul() {
|
||||
|
|
|
|||
Loading…
Reference in a new issue