Remove unnecessary imports (#567)

Fix for latest clippy / nightly upgrade

- [x] no changelog update needed
This commit is contained in:
Gwilym Inzani 2024-02-20 22:27:00 +00:00 committed by GitHub
commit 0975530e5c
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 3 additions and 14 deletions

View file

@ -32,7 +32,6 @@ use core::{
borrow::Borrow, borrow::Borrow,
fmt::Debug, fmt::Debug,
hash::{BuildHasher, BuildHasherDefault, Hash}, hash::{BuildHasher, BuildHasherDefault, Hash},
iter::FromIterator,
num::Wrapping, num::Wrapping,
ops::Index, ops::Index,
}; };
@ -949,8 +948,6 @@ impl core::ops::Add<i32> for HashType {
mod test { mod test {
use core::{cell::RefCell, hash::Hasher}; use core::{cell::RefCell, hash::Hasher};
use alloc::vec::Vec;
use super::*; use super::*;
#[test] #[test]

View file

@ -1,4 +1,4 @@
use std::{collections::HashSet, iter::FromIterator}; use std::collections::HashSet;
use crate::{ use crate::{
colour::Colour, colour::Colour,

View file

@ -11,7 +11,6 @@ use agb::{
}, },
input::Button, input::Button,
}; };
use core::convert::TryInto;
#[derive(PartialEq, Eq)] #[derive(PartialEq, Eq)]
enum State { enum State {

View file

@ -81,10 +81,7 @@
//! # } //! # }
//! ``` //! ```
use core::{ use core::ops::{Mul, MulAssign};
convert::TryFrom,
ops::{Mul, MulAssign},
};
use agb_fixnum::{Num, Vector2D}; use agb_fixnum::{Num, Vector2D};

View file

@ -4,7 +4,7 @@ use super::{
set_graphics_mode, set_graphics_settings, DisplayMode, GraphicsSettings, HEIGHT, WIDTH, set_graphics_mode, set_graphics_settings, DisplayMode, GraphicsSettings, HEIGHT, WIDTH,
}; };
use core::{convert::TryInto, marker::PhantomData}; use core::marker::PhantomData;
const BITMAP_MODE_3: MemoryMapped2DArray<u16, { WIDTH as usize }, { HEIGHT as usize }> = const BITMAP_MODE_3: MemoryMapped2DArray<u16, { WIDTH as usize }, { HEIGHT as usize }> =
unsafe { MemoryMapped2DArray::new(0x600_0000) }; unsafe { MemoryMapped2DArray::new(0x600_0000) };

View file

@ -183,8 +183,6 @@ enum ColourMode {
#[allow(clippy::module_inception)] #[allow(clippy::module_inception)]
mod attributes { mod attributes {
use crate::display::Priority;
use super::*; use super::*;
#[bitsize(16)] #[bitsize(16)]

View file

@ -1,7 +1,6 @@
#![deny(missing_docs)] #![deny(missing_docs)]
use crate::fixnum::Vector2D; use crate::fixnum::Vector2D;
use bitflags::bitflags; use bitflags::bitflags;
use core::convert::From;
/// Tri-state enum. Allows for -1, 0 and +1. /// Tri-state enum. Allows for -1, 0 and +1.
/// Useful if checking if the D-Pad is pointing left, right, or unpressed. /// Useful if checking if the D-Pad is pointing left, right, or unpressed.

View file

@ -162,7 +162,6 @@ impl Level {
mod levels { mod levels {
use super::*; use super::*;
use agb::fixnum::Vector2D;
include!(concat!(env!("OUT_DIR"), "/levels.rs")); include!(concat!(env!("OUT_DIR"), "/levels.rs"));
} }