mirror of
https://github.com/nushell/nushell.git
synced 2025-08-10 10:48:37 +02:00
clippy
This commit is contained in:
@ -119,6 +119,7 @@ impl EngineState {
|
||||
.expect("internal error: missing variable")
|
||||
}
|
||||
|
||||
#[allow(clippy::borrowed_box)]
|
||||
pub fn get_decl(&self, decl_id: DeclId) -> &Box<dyn Command> {
|
||||
self.decls
|
||||
.get(decl_id)
|
||||
@ -460,6 +461,7 @@ impl<'a> StateWorkingSet<'a> {
|
||||
}
|
||||
}
|
||||
|
||||
#[allow(clippy::borrowed_box)]
|
||||
pub fn get_decl(&self, decl_id: DeclId) -> &Box<dyn Command> {
|
||||
let num_permanent_decls = self.permanent_state.num_decls();
|
||||
if decl_id < num_permanent_decls {
|
||||
|
Reference in New Issue
Block a user