Use byte instead of i
The identifier `i` is predominantly used for indexing an array but we are using it as a place holder for the iterated value of an array that is then printed. The identifier `byte` is more descriptive. Done in preparation for adding similar code to the `ecdh` module.
This commit is contained in:
parent
91106f5685
commit
4ded2c0478
|
@ -101,8 +101,8 @@ impl fmt::Debug for DisplaySecret {
|
||||||
|
|
||||||
impl fmt::Display for DisplaySecret {
|
impl fmt::Display for DisplaySecret {
|
||||||
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result {
|
||||||
for i in &self.secret {
|
for byte in &self.secret {
|
||||||
write!(f, "{:02x}", i)?;
|
write!(f, "{:02x}", byte)?;
|
||||||
}
|
}
|
||||||
Ok(())
|
Ok(())
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue