Move HEADER_LEN constant to top of file.
This commit is contained in:
parent
28904e01c7
commit
94a07b05cc
|
@ -17,6 +17,9 @@ use crate::{constants, types::*, Network};
|
|||
|
||||
use super::message::Message;
|
||||
|
||||
/// The length of a Bitcoin message header.
|
||||
const HEADER_LEN: usize = 24usize;
|
||||
|
||||
/// A codec which produces Bitcoin messages from byte streams and vice versa.
|
||||
pub struct Codec {
|
||||
builder: Builder,
|
||||
|
@ -89,9 +92,6 @@ impl Builder {
|
|||
}
|
||||
}
|
||||
|
||||
/// The length of a Bitcoin message header.
|
||||
const HEADER_LEN: usize = 24usize;
|
||||
|
||||
// ======== Encoding =========
|
||||
|
||||
impl Codec {
|
||||
|
|
Loading…
Reference in New Issue