mirror of
https://github.com/saymrwulf/risc0-curve25519-dalek-source.git
synced 2026-09-07 20:30:39 +00:00
Remove extra line and unneeded XXX comment from Scalar::hash_from_bytes.
This commit is contained in:
parent
37935674eb
commit
3854eb0fd8
1 changed files with 0 additions and 2 deletions
|
|
@ -480,7 +480,6 @@ impl Scalar {
|
||||||
/// let s = Scalar::hash_from_bytes::<Sha512>(msg.as_bytes());
|
/// let s = Scalar::hash_from_bytes::<Sha512>(msg.as_bytes());
|
||||||
/// # }
|
/// # }
|
||||||
/// ```
|
/// ```
|
||||||
///
|
|
||||||
pub fn hash_from_bytes<D>(input: &[u8]) -> Scalar
|
pub fn hash_from_bytes<D>(input: &[u8]) -> Scalar
|
||||||
where D: Digest<OutputSize = U64> + Default
|
where D: Digest<OutputSize = U64> + Default
|
||||||
{
|
{
|
||||||
|
|
@ -497,7 +496,6 @@ impl Scalar {
|
||||||
pub fn from_hash<D>(hash: D) -> Scalar
|
pub fn from_hash<D>(hash: D) -> Scalar
|
||||||
where D: Digest<OutputSize = U64> + Default
|
where D: Digest<OutputSize = U64> + Default
|
||||||
{
|
{
|
||||||
// XXX this seems clumsy
|
|
||||||
let mut output = [0u8; 64];
|
let mut output = [0u8; 64];
|
||||||
output.copy_from_slice(hash.result().as_slice());
|
output.copy_from_slice(hash.result().as_slice());
|
||||||
Scalar::from_bytes_mod_order_wide(&output)
|
Scalar::from_bytes_mod_order_wide(&output)
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue