mirror of
https://github.com/asterinas/asterinas.git
synced 2025-06-24 01:43:22 +00:00
Remove useless #[allow(lint)]
This commit is contained in:
committed by
Tate, Hongliang Tian
parent
b42d596ec4
commit
b415538097
@ -58,7 +58,6 @@ const EXFAT_UNUSED: u8 = 0x00;
|
||||
#[allow(dead_code)]
|
||||
const EXFAT_INVAL: u8 = 0x80;
|
||||
const EXFAT_BITMAP: u8 = 0x81;
|
||||
#[allow(dead_code)]
|
||||
const EXFAT_UPCASE: u8 = 0x82;
|
||||
#[allow(dead_code)]
|
||||
const EXFAT_VOLUME: u8 = 0x83;
|
||||
|
@ -1,7 +1,5 @@
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
|
||||
#![allow(unused_variables)]
|
||||
|
||||
use super::{inode::MAX_FNAME_LEN, prelude::*};
|
||||
|
||||
/// The data structure in a directory's data block. It is stored in a linked list.
|
||||
|
@ -109,7 +109,6 @@ struct RamInode {
|
||||
}
|
||||
|
||||
/// Inode inner specifics.
|
||||
#[allow(clippy::large_enum_variant)]
|
||||
enum Inner {
|
||||
Dir(RwLock<DirEntry>),
|
||||
File(PageCache),
|
||||
|
@ -41,7 +41,6 @@ pub enum IpcControlCmd {
|
||||
}
|
||||
|
||||
#[derive(Debug)]
|
||||
#[allow(dead_code)]
|
||||
pub struct IpcPermission {
|
||||
key: key_t,
|
||||
/// Owner's UID
|
||||
|
@ -1,5 +1,4 @@
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
#![allow(non_camel_case_types)]
|
||||
|
||||
use crate::{prelude::*, process::Pid};
|
||||
|
||||
|
@ -1,7 +1,5 @@
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
|
||||
#![allow(dead_code)]
|
||||
|
||||
use aster_rights::{Dup, Read, TRights, Write};
|
||||
use aster_rights_proc::require;
|
||||
use ostd::sync::{PreemptDisabled, RwLockReadGuard, RwLockWriteGuard};
|
||||
|
@ -1,7 +1,5 @@
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
|
||||
#![allow(dead_code)]
|
||||
|
||||
use core::sync::atomic::{AtomicU32, Ordering};
|
||||
|
||||
use aster_rights::{ReadOp, WriteOp};
|
||||
|
@ -171,7 +171,6 @@ impl Process {
|
||||
Some(Task::current()?.as_posix_thread()?.process())
|
||||
}
|
||||
|
||||
#[allow(clippy::too_many_arguments)]
|
||||
fn new(
|
||||
pid: Pid,
|
||||
parent: Weak<Process>,
|
||||
|
@ -1,7 +1,6 @@
|
||||
// SPDX-License-Identifier: MPL-2.0
|
||||
|
||||
#![allow(dead_code)]
|
||||
#![allow(unused_variables)]
|
||||
|
||||
//! This module is used to parse elf file content to get elf_load_info.
|
||||
//! When create a process from elf file, we will use the elf_load_info to construct the VmSpace
|
||||
|
@ -21,7 +21,6 @@ use super::{
|
||||
};
|
||||
use crate::{prelude::*, thread::Thread};
|
||||
|
||||
#[allow(unused)]
|
||||
pub fn init() {
|
||||
let preempt_scheduler = Box::new(PreemptScheduler::default());
|
||||
let scheduler = Box::<PreemptScheduler<Thread, Task>>::leak(preempt_scheduler);
|
||||
|
@ -237,7 +237,6 @@ impl MMapOptions {
|
||||
self.typ
|
||||
}
|
||||
|
||||
#[allow(unused)]
|
||||
pub fn flags(&self) -> MMapFlags {
|
||||
self.flags
|
||||
}
|
||||
|
@ -75,7 +75,6 @@ fn set_new_stack(sig_stack_addr: Vaddr, old_stack: Option<&SigStack>, ctx: &Cont
|
||||
Ok(())
|
||||
}
|
||||
|
||||
#[allow(non_camel_case_types)]
|
||||
#[derive(Debug, Clone, Copy, Pod)]
|
||||
#[repr(C)]
|
||||
struct stack_t {
|
||||
|
@ -13,7 +13,6 @@ use crate::{current_userspace, net::socket::SocketAddr, prelude::*};
|
||||
#[repr(i32)]
|
||||
#[derive(Debug, Clone, Copy, TryFromInt, PartialEq, Eq)]
|
||||
#[allow(non_camel_case_types)]
|
||||
#[allow(dead_code)]
|
||||
pub enum CSocketAddrFamily {
|
||||
AF_UNSPEC = 0,
|
||||
/// Unix domain sockets
|
||||
|
@ -46,10 +46,7 @@ where
|
||||
let mut bytes: [u8; CSocketAddrUnix::MAX_LEN + 1] = Pod::new_zeroed();
|
||||
|
||||
bytes[..2].copy_from_slice(&(CSocketAddrFamily::AF_UNIX as u16).to_ne_bytes());
|
||||
#[allow(clippy::assertions_on_constants)]
|
||||
const {
|
||||
assert!(CSocketAddrUnix::PATH_OFFSET == 2)
|
||||
};
|
||||
const { assert!(CSocketAddrUnix::PATH_OFFSET == 2) };
|
||||
|
||||
let sun_path = &mut bytes[CSocketAddrUnix::PATH_OFFSET..];
|
||||
|
||||
|
@ -36,7 +36,6 @@ where
|
||||
}
|
||||
}
|
||||
|
||||
#[allow(dead_code)]
|
||||
impl<K, V> IntervalSet<K, V>
|
||||
where
|
||||
K: Clone + Ord,
|
||||
|
Reference in New Issue
Block a user