mirror of
https://github.com/sigp/lighthouse.git
synced 2026-04-16 20:39:10 +00:00
Fix Rust 1.83 Clippy lints (#6629)
* Fix Rust 1.83 Clippy lints * Cargo fmt
This commit is contained in:
@@ -528,9 +528,9 @@ impl BeaconNodeHttpClient {
|
||||
self.post_with_response(path, &()).await
|
||||
}
|
||||
|
||||
///
|
||||
/// Analysis endpoints.
|
||||
///
|
||||
/*
|
||||
Analysis endpoints.
|
||||
*/
|
||||
|
||||
/// `GET` lighthouse/analysis/block_rewards?start_slot,end_slot
|
||||
pub async fn get_lighthouse_analysis_block_rewards(
|
||||
|
||||
@@ -120,7 +120,7 @@ pub struct Eth2NetArchiveAndDirectory<'a> {
|
||||
pub genesis_state_source: GenesisStateSource,
|
||||
}
|
||||
|
||||
impl<'a> Eth2NetArchiveAndDirectory<'a> {
|
||||
impl Eth2NetArchiveAndDirectory<'_> {
|
||||
/// The directory that should be used to store files downloaded for this net.
|
||||
pub fn dir(&self) -> PathBuf {
|
||||
env::var("CARGO_MANIFEST_DIR")
|
||||
|
||||
@@ -105,7 +105,7 @@ impl<'a> AlignedRecordDecorator<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> Write for AlignedRecordDecorator<'a> {
|
||||
impl Write for AlignedRecordDecorator<'_> {
|
||||
fn write(&mut self, buf: &[u8]) -> Result<usize> {
|
||||
if buf.iter().any(u8::is_ascii_control) {
|
||||
let filtered = buf
|
||||
@@ -124,7 +124,7 @@ impl<'a> Write for AlignedRecordDecorator<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
impl<'a> slog_term::RecordDecorator for AlignedRecordDecorator<'a> {
|
||||
impl slog_term::RecordDecorator for AlignedRecordDecorator<'_> {
|
||||
fn reset(&mut self) -> Result<()> {
|
||||
self.message_active = false;
|
||||
self.message_count = 0;
|
||||
|
||||
@@ -15,7 +15,7 @@ use types::test_utils::generate_deterministic_keypair;
|
||||
/// A very weak password with which to encrypt the keystores.
|
||||
pub const INSECURE_PASSWORD: &[u8] = &[50; 51];
|
||||
|
||||
impl<'a> Builder<'a> {
|
||||
impl Builder<'_> {
|
||||
/// Generate the voting keystore using a deterministic, well-known, **unsafe** keypair.
|
||||
///
|
||||
/// **NEVER** use these keys in production!
|
||||
|
||||
Reference in New Issue
Block a user