From 60e78768a4c675e221ac12bed2476f0e351de515 Mon Sep 17 00:00:00 2001 From: GBA bot Date: Tue, 4 Jan 2022 00:16:25 +0000 Subject: [PATCH] You don't need extern crate agb; any more --- agb/examples/allocation.rs | 1 - agb/examples/beep.rs | 2 -- agb/examples/bitmap3.rs | 2 -- agb/examples/bitmap4.rs | 2 -- agb/examples/chicken.rs | 1 - agb/examples/mixer_basic.rs | 2 -- agb/examples/multiple_video.rs | 2 -- agb/examples/output.rs | 2 -- agb/examples/panic.rs | 2 -- agb/examples/stereo_sound.rs | 2 -- agb/examples/syscall.rs | 1 - agb/examples/test_logo.rs | 2 -- agb/examples/wave.rs | 2 -- agb/src/display/object.rs | 4 ---- agb/src/lib.rs | 5 ----- book/games/pong/src/main.rs | 4 ---- book/src/pong/02_the_gba_struct.md | 1 - examples/the-purple-night/src/main.rs | 1 - template/src/main.rs | 4 ---- 19 files changed, 42 deletions(-) diff --git a/agb/examples/allocation.rs b/agb/examples/allocation.rs index 327ed07e..67a8e3bf 100644 --- a/agb/examples/allocation.rs +++ b/agb/examples/allocation.rs @@ -1,7 +1,6 @@ #![no_std] #![no_main] -extern crate agb; extern crate alloc; use alloc::boxed::Box; diff --git a/agb/examples/beep.rs b/agb/examples/beep.rs index ec377000..39518009 100644 --- a/agb/examples/beep.rs +++ b/agb/examples/beep.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::sound; #[agb::entry] diff --git a/agb/examples/bitmap3.rs b/agb/examples/bitmap3.rs index 702dcb82..98c668d2 100644 --- a/agb/examples/bitmap3.rs +++ b/agb/examples/bitmap3.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::display; struct Vector2D { diff --git a/agb/examples/bitmap4.rs b/agb/examples/bitmap4.rs index 09af1688..47a8ccbc 100644 --- a/agb/examples/bitmap4.rs +++ b/agb/examples/bitmap4.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::display; #[agb::entry] diff --git a/agb/examples/chicken.rs b/agb/examples/chicken.rs index 31772109..aec196fa 100644 --- a/agb/examples/chicken.rs +++ b/agb/examples/chicken.rs @@ -1,7 +1,6 @@ #![no_std] #![no_main] -extern crate agb; use agb::{ display::{background::Map, object::ObjectStandard, HEIGHT, WIDTH}, input::Button, diff --git a/agb/examples/mixer_basic.rs b/agb/examples/mixer_basic.rs index ed8d3cf6..c4780753 100644 --- a/agb/examples/mixer_basic.rs +++ b/agb/examples/mixer_basic.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::input::{Button, ButtonController, Tri}; use agb::number::Num; use agb::sound::mixer::SoundChannel; diff --git a/agb/examples/multiple_video.rs b/agb/examples/multiple_video.rs index 4b1ffd50..8de24f16 100644 --- a/agb/examples/multiple_video.rs +++ b/agb/examples/multiple_video.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::display; struct Vector2D { diff --git a/agb/examples/output.rs b/agb/examples/output.rs index b7d17e96..4a5c06ae 100644 --- a/agb/examples/output.rs +++ b/agb/examples/output.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - #[agb::entry] fn main() -> ! { let count = agb::interrupt::Mutex::new(0); diff --git a/agb/examples/panic.rs b/agb/examples/panic.rs index 80fd6d7b..0a740826 100644 --- a/agb/examples/panic.rs +++ b/agb/examples/panic.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::display; #[agb::entry] diff --git a/agb/examples/stereo_sound.rs b/agb/examples/stereo_sound.rs index 27f82015..1667e259 100644 --- a/agb/examples/stereo_sound.rs +++ b/agb/examples/stereo_sound.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::sound::mixer::SoundChannel; use agb::{include_wav, Gba}; diff --git a/agb/examples/syscall.rs b/agb/examples/syscall.rs index 6bd8c2fe..995fda9d 100644 --- a/agb/examples/syscall.rs +++ b/agb/examples/syscall.rs @@ -1,7 +1,6 @@ #![no_std] #![no_main] -extern crate agb; use agb::{display, syscall}; #[agb::entry] diff --git a/agb/examples/test_logo.rs b/agb/examples/test_logo.rs index dad1d98e..806678fb 100644 --- a/agb/examples/test_logo.rs +++ b/agb/examples/test_logo.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::display::example_logo; #[agb::entry] diff --git a/agb/examples/wave.rs b/agb/examples/wave.rs index fdf59877..3e8264bb 100644 --- a/agb/examples/wave.rs +++ b/agb/examples/wave.rs @@ -1,8 +1,6 @@ #![no_std] #![no_main] -extern crate agb; - use agb::{ display::example_logo, interrupt::{Interrupt, Mutex}, diff --git a/agb/src/display/object.rs b/agb/src/display/object.rs index e980dff6..2fbd2329 100644 --- a/agb/src/display/object.rs +++ b/agb/src/display/object.rs @@ -27,8 +27,6 @@ const TILE_SPRITE: MemoryMapped1DArray = /// # #![no_std] /// # #![no_main] /// # -/// # extern crate agb; -/// # /// # use agb::Gba; /// # /// # #[agb::entry] @@ -63,8 +61,6 @@ struct ObjectLoan<'a> { /// # #![no_std] /// # #![no_main] /// # -/// # extern crate agb; -/// # /// # use agb::Gba; /// use agb::display::object::Size; /// diff --git a/agb/src/lib.rs b/agb/src/lib.rs index 57845a04..58538e70 100644 --- a/agb/src/lib.rs +++ b/agb/src/lib.rs @@ -122,9 +122,6 @@ pub use agb_image_converter::include_gfx; /// #![no_std] /// #![no_main] /// -/// // Required to set panic handlers -/// extern crate agb; -/// /// use agb::Gba; /// /// #[agb::entry] @@ -198,8 +195,6 @@ static mut GBASINGLE: single::Singleton = single::Singleton::new(unsafe { G /// #![no_std] /// #![no_main] /// -/// extern crate agb; -/// /// use agb::Gba; /// /// #[agb::entry] diff --git a/book/games/pong/src/main.rs b/book/games/pong/src/main.rs index c90c3699..b559d005 100644 --- a/book/games/pong/src/main.rs +++ b/book/games/pong/src/main.rs @@ -10,10 +10,6 @@ // which won't be a particularly clear error message. #![no_main] -// This is required in order to ensure that the panic handler defined in `agb` is set -// up correctly. -extern crate agb; - use agb::display::object::Size; use agb::Gba; diff --git a/book/src/pong/02_the_gba_struct.md b/book/src/pong/02_the_gba_struct.md index 4a8f83ed..d2d7046e 100644 --- a/book/src/pong/02_the_gba_struct.md +++ b/book/src/pong/02_the_gba_struct.md @@ -19,7 +19,6 @@ Replace the content of the `main` function with the following: ```rust,ignore # #![no_std] # #![no_main] -# extern crate agb; # #[agb::entry] # fn main() -> ! { let mut gba = agb::Gba::new(); diff --git a/examples/the-purple-night/src/main.rs b/examples/the-purple-night/src/main.rs index 08099af7..3ce4b92a 100644 --- a/examples/the-purple-night/src/main.rs +++ b/examples/the-purple-night/src/main.rs @@ -1,7 +1,6 @@ #![no_std] #![no_main] -extern crate agb; extern crate alloc; mod rng; diff --git a/template/src/main.rs b/template/src/main.rs index 9edf921a..48348109 100644 --- a/template/src/main.rs +++ b/template/src/main.rs @@ -10,10 +10,6 @@ // which won't be a particularly clear error message. #![no_main] -// This is required in order to ensure that the panic handler defined in `agb` is set -// up correctly. -extern crate agb; - use agb::{display, syscall}; // The main function must take 0 arguments and never return. The agb::entry decorator