aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFuwn <[email protected]>2022-03-04 01:57:27 -0800
committerFuwn <[email protected]>2022-03-04 01:57:27 -0800
commitbd47c8e6dd0b7b988c210ab752127c413c4aab85 (patch)
tree83f0051c6c9f4021c5a4edc8bd1beebfbba3de73
parentadd me to AUTHORS.md (diff)
downloadctru-rs-bd47c8e6dd0b7b988c210ab752127c413c4aab85.tar.xz
ctru-rs-bd47c8e6dd0b7b988c210ab752127c413c4aab85.zip
fix(ctru-rs): warningsHEADmain
-rw-r--r--ctru-rs/src/applets/swkbd.rs5
-rw-r--r--ctru-rs/src/console.rs1
-rw-r--r--ctru-rs/src/services/fs.rs2
-rw-r--r--ctru-rs/src/services/hid.rs4
-rw-r--r--ctru-rs/src/thread.rs2
5 files changed, 6 insertions, 8 deletions
diff --git a/ctru-rs/src/applets/swkbd.rs b/ctru-rs/src/applets/swkbd.rs
index 5091539..54098c7 100644
--- a/ctru-rs/src/applets/swkbd.rs
+++ b/ctru-rs/src/applets/swkbd.rs
@@ -1,5 +1,4 @@
use std::iter::once;
-use std::mem;
use std::str;
use std::convert::TryInto;
@@ -59,7 +58,7 @@ pub enum ValidInput {
FixedLen,
}
-/// Keyboard feature flags
+// Keyboard feature flags
bitflags! {
pub struct Features: u32 {
const PARENTAL_PIN = 1 << 0;
@@ -74,7 +73,7 @@ bitflags! {
}
}
-/// Keyboard input filtering flags
+// Keyboard input filtering flags
bitflags! {
pub struct Filters: u32 {
const DIGITS = 1 << 0;
diff --git a/ctru-rs/src/console.rs b/ctru-rs/src/console.rs
index eb8df6b..9f6643a 100644
--- a/ctru-rs/src/console.rs
+++ b/ctru-rs/src/console.rs
@@ -1,5 +1,4 @@
use std::default::Default;
-use std::mem;
use libctru::{PrintConsole, consoleInit, consoleSelect, consoleClear, consoleSetWindow};
diff --git a/ctru-rs/src/services/fs.rs b/ctru-rs/src/services/fs.rs
index 29d30b6..a2cb830 100644
--- a/ctru-rs/src/services/fs.rs
+++ b/ctru-rs/src/services/fs.rs
@@ -878,7 +878,7 @@ fn truncate_utf16_at_nul<'a>(v: &'a [u16]) -> &'a [u16] {
// Implementations using this method have to adhere to two guarantees:
// * The implementation of read never reads the buffer provided.
// * The implementation of read correctly reports how many bytes were written.
-unsafe fn read_to_end_uninitialized(r: &mut Read, buf: &mut Vec<u8>) -> IoResult<usize> {
+unsafe fn read_to_end_uninitialized(r: &mut dyn Read, buf: &mut Vec<u8>) -> IoResult<usize> {
let start_len = buf.len();
buf.reserve(16);
diff --git a/ctru-rs/src/services/hid.rs b/ctru-rs/src/services/hid.rs
index 12aab2d..f318bb3 100644
--- a/ctru-rs/src/services/hid.rs
+++ b/ctru-rs/src/services/hid.rs
@@ -5,8 +5,8 @@
//! the accelerometer, and the gyroscope.
-/// A set of flags corresponding to the button and directional pad
-/// inputs on the 3DS
+// A set of flags corresponding to the button and directional pad
+// inputs on the 3DS
bitflags! {
#[derive(Default)]
pub struct KeyPad: u32 {
diff --git a/ctru-rs/src/thread.rs b/ctru-rs/src/thread.rs
index 481e559..8c49a1e 100644
--- a/ctru-rs/src/thread.rs
+++ b/ctru-rs/src/thread.rs
@@ -724,7 +724,7 @@ impl fmt::Debug for Thread {
/// ```
///
/// [`Result`]: ../../std/result/enum.Result.html
-pub type Result<T> = ::std::result::Result<T, Box<Any + Send + 'static>>;
+pub type Result<T> = ::std::result::Result<T, Box<dyn Any + Send + 'static>>;
// This packet is used to communicate the return value between the child thread
// and the parent thread. Memory is shared through the `Arc` within and there's