Skip to content

Commit

Permalink
Lints
Browse files Browse the repository at this point in the history
  • Loading branch information
dr-orlovsky committed Aug 30, 2021
1 parent aaad725 commit 758d15a
Show file tree
Hide file tree
Showing 7 changed files with 19 additions and 20 deletions.
15 changes: 8 additions & 7 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "internet2"
version = "0.5.0-alpha.1"
version = "0.5.0-alpha.2"
license = "Apache-2.0"
authors = ["Dr. Maxim Orlovsky <[email protected]>"]
description = "Rust implementation for the stack of Internet2 protocols"
Expand All @@ -24,7 +24,7 @@ crate-type = ["rlib", "staticlib"]
# -----------------------------------------
amplify = "3.9.1"
strict_encoding = { version = "1.7", default-features = false, features = ["derive"] }
lightning_encoding = "0.5.0-beta.1"
lightning_encoding = "0.5.0-beta.2"
inet2_addr = { version = "0.5", features = ["strict_encoding", "stringly_conversions"], path = "./addr" }
inet2_derive = { version = "0.5.0-alpha.1", default-features = false, optional = true, path = "./derive" }
# Dependencies on core rust-bitcoin & cryptography
Expand Down
2 changes: 1 addition & 1 deletion derive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -24,5 +24,5 @@ amplify = "3.9.1"
internet2 = { path = ".." }
lnpbp = "0.5.0-beta.3"
strict_encoding = "1.7.1"
lightning_encoding = "0.5.0-beta.1"
lightning_encoding = "0.5.0-beta.2"
bitcoin = "0.27"
1 change: 1 addition & 0 deletions src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,7 @@
//dead_code,
//missing_docs
)]
#![allow(unused_variables, dead_code)]
// TODO: when we will be ready for the release #![deny(missing_docs, dead_code)]
// This is required because of incomplete rust async implementation and can be
// removed after async trait feature completion in rust compiler
Expand Down
2 changes: 1 addition & 1 deletion src/presentation/tlv.rs
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ use lightning_encoding::{self, BigSize, LightningDecode};

use super::{Error, EvenOdd, Unmarshall, UnmarshallFn};

pub type Map = BTreeMap<Type, RawRecord>;
pub type UnknownMap = BTreeMap<usize, Box<[u8]>>;

/// TLV type field value
#[derive(
Expand Down
2 changes: 1 addition & 1 deletion src/session/noise/conduit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,7 @@ impl NoiseEncryptor {
)?;
self.increment_nonce();

&chacha::encrypt(
let _ = &chacha::encrypt(
&self.sending_key,
self.sending_nonce as u64,
&[0; 0],
Expand Down
13 changes: 5 additions & 8 deletions src/transport/zmqsocket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -435,10 +435,10 @@ impl Duplex for Connection {
// We panic here because this is a program architecture design
// error and developer must be notified about it; the program using
// this pattern can't work
panic!(format!(
panic!(
"Split operation is impossible for ZMQ stream type {}",
self.api_type
));
);
}
}
}
Expand All @@ -455,10 +455,7 @@ impl Bipolar for Connection {
panic!("ZMQ streams of different type can't be joined");
}
if input.api_type != ZmqType::Push || input.api_type == ZmqType::Pull {
panic!(format!(
"ZMQ streams of {} type can't be joined",
input.api_type
));
panic!("ZMQ streams of {} type can't be joined", input.api_type);
}
Self {
api_type: input.api_type.clone(),
Expand All @@ -474,10 +471,10 @@ impl Bipolar for Connection {
// We panic here because this is a program architecture design
// error and developer must be notified about it; the program using
// this pattern can't work
panic!(format!(
panic!(
"Split operation is impossible for ZMQ stream type {}",
self.api_type
));
);
}
}
}
Expand Down

0 comments on commit 758d15a

Please sign in to comment.