From 5b39efb79d8e28d02bd77fcd392b35fa4962b310 Mon Sep 17 00:00:00 2001 From: Sofia Date: Thu, 28 May 2026 23:40:39 +0300 Subject: [PATCH] Clean up some warnings --- src/font.rs | 2 +- src/main.rs | 4 ++-- src/state.rs | 1 - src/states.rs | 14 ++++---------- 4 files changed, 7 insertions(+), 14 deletions(-) diff --git a/src/font.rs b/src/font.rs index 6ab0f48..1785783 100644 --- a/src/font.rs +++ b/src/font.rs @@ -6,7 +6,7 @@ use alloc::vec; use alloc::vec::Vec; use alloc::{borrow::ToOwned, string::String}; -use crate::display::{self, Color, Display, Position, Rgb565}; +use crate::display::{self, Display, Position, Rgb565}; static OPEN_SANS: &'static [u8] = include_bytes!("./OpenSans_Condensed-Regular.ttf"); diff --git a/src/main.rs b/src/main.rs index b29ec66..98f6a53 100644 --- a/src/main.rs +++ b/src/main.rs @@ -10,11 +10,11 @@ use core::mem::MaybeUninit; -use alloc::{boxed::Box, format, string::ToString}; +use alloc::boxed::Box; use esp_hal::{ clock::CpuClock, delay::Delay, - gpio::{InputConfig, Level, Output, OutputConfig}, + gpio::{Level, Output, OutputConfig}, interrupt::software::SoftwareInterruptControl, main, spi::master::{Config, Spi}, diff --git a/src/state.rs b/src/state.rs index 03d670c..f0b145a 100644 --- a/src/state.rs +++ b/src/state.rs @@ -3,7 +3,6 @@ use esp_hal::{Blocking, delay::Delay}; use crate::{ async_io::AsyncIO, - at_commands::ATCommands, display::{Color, Display, Position, Rgb565}, font::{FontRenderer, HorizontalAlignment, VerticalAlignment}, }; diff --git a/src/states.rs b/src/states.rs index d1ce3ab..e0d18a6 100644 --- a/src/states.rs +++ b/src/states.rs @@ -1,19 +1,13 @@ use core::iter::repeat; -use alloc::{ - borrow::ToOwned, - boxed::Box, - format, - string::{String, ToString}, -}; +use alloc::{borrow::ToOwned, boxed::Box, format, string::String}; use esp_hal::time::{Duration, Instant}; use crate::{ async_io::ATPromise, at_commands::{ - ATCommand, ATInformationCommand, CheckPinCommand, EnterPinCommand, - ListTECharacterSetsCommand, SMSFormat, SelectSMSFormatCommand, SendSMSCommand, - SetTECharsetCommand, StubATCommand, TECharset, + ATCommand, ATInformationCommand, CheckPinCommand, EnterPinCommand, SMSFormat, + SelectSMSFormatCommand, SetTECharsetCommand, TECharset, }, display::{Position, Rgb565}, font::{HorizontalAlignment, VerticalAlignment}, @@ -120,7 +114,7 @@ impl State for InitATState { Some(Box::new(state)) } - fn draw(&self, data: &mut StateData) {} + fn draw(&self, _: &mut StateData) {} } #[derive(Clone)]