clippy
9 errors
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 9 |
Warning | 0 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.75.0 (82e1608df 2023-12-21)
- cargo 1.75.0 (1d8b05cdd 2023-11-20)
- clippy 0.1.75 (82e1608 2023-12-21)
Annotations
Check failure on line 99 in src/commands/init/mod.rs
github-actions / clippy
cannot assign to `app.server.name` because it is borrowed
error[E0506]: cannot assign to `app.server.name` because it is borrowed
--> src/commands/init/mod.rs:99:9
|
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| -------------------------------------
| |
| `app.server.name` is borrowed here
| argument requires that `app` is borrowed for `'static`
...
99 | app.server.name = name.clone();
| ^^^^^^^^^^^^^^^ `app.server.name` is assigned to here but it was already borrowed
Check failure on line 96 in src/commands/init/mod.rs
github-actions / clippy
cannot assign to `app.network` because it is borrowed
error[E0506]: cannot assign to `app.network` because it is borrowed
--> src/commands/init/mod.rs:96:13
|
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| -------------------------------------
| |
| `app.network` is borrowed here
| argument requires that `app` is borrowed for `'static`
...
96 | app.network = Some(nw);
| ^^^^^^^^^^^ `app.network` is assigned to here but it was already borrowed
Check failure on line 92 in src/commands/init/mod.rs
github-actions / clippy
cannot borrow `app` as immutable because it is also borrowed as mutable
error[E0502]: cannot borrow `app` as immutable because it is also borrowed as mutable
--> src/commands/init/mod.rs:92:13
|
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| -------------------------------------
| |
| mutable borrow occurs here
| argument requires that `app` is borrowed for `'static`
...
92 | app.info(format!(
| ^^^ immutable borrow occurs here
Check failure on line 81 in src/commands/init/mod.rs
github-actions / clippy
cannot assign to `app.network` because it is borrowed
error[E0506]: cannot assign to `app.network` because it is borrowed
--> src/commands/init/mod.rs:81:9
|
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| -------------------------------------
| |
| `app.network` is borrowed here
| argument requires that `app` is borrowed for `'static`
...
81 | app.network = Some(Network::default());
| ^^^^^^^^^^^ `app.network` is assigned to here but it was already borrowed
Check failure on line 70 in src/commands/init/mod.rs
github-actions / clippy
temporary value dropped while borrowed
error[E0716]: temporary value dropped while borrowed
--> src/commands/init/mod.rs:70:27
|
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| ^^^^^^^^^^^^^------------------------
| |
| creates a temporary value which is freed while still in use
| argument requires that borrow lasts for `'static`
71 | } else {
| - temporary value is freed at the end of this statement
Check failure on line 70 in src/commands/init/mod.rs
github-actions / clippy
`app` does not live long enough
error[E0597]: `app` does not live long enough
--> src/commands/init/mod.rs:70:27
|
63 | let mut app = base_app.upgrade_with_default_server()?;
| ------- binding `app` declared here
...
70 | InitType::Packwiz(app.packwiz().get_file_provider(&src)?)
| ^^^----------------------------------
| |
| borrowed value does not live long enough
| argument requires that `app` is borrowed for `'static`
...
289 | }
| - `app` dropped here while still borrowed
Check failure on line 65 in src/interop/packwiz.rs
github-actions / clippy
`provider` does not live long enough
error[E0597]: `provider` does not live long enough
--> src/interop/packwiz.rs:65:33
|
62 | pub async fn import_all(&mut self, from: &str) -> Result<()> {
| --------- lifetime `'1` appears in the type of `self`
63 | let provider = self.get_file_provider(from)?;
| -------- binding `provider` declared here
64 |
65 | self.import_from_source(&provider).await
| ------------------------^^^^^^^^^-
| | |
| | borrowed value does not live long enough
| argument requires that `provider` is borrowed for `'1`
66 | }
| - `provider` dropped here while still borrowed
Check failure on line 65 in src/interop/packwiz.rs
github-actions / clippy
cannot borrow `*self` as mutable because it is also borrowed as immutable
error[E0502]: cannot borrow `*self` as mutable because it is also borrowed as immutable
--> src/interop/packwiz.rs:65:9
|
62 | pub async fn import_all(&mut self, from: &str) -> Result<()> {
| --------- lifetime `'1` appears in the type of `self`
63 | let provider = self.get_file_provider(from)?;
| ----------------------------
| |
| immutable borrow occurs here
| argument requires that `*self` is borrowed for `'1`
64 |
65 | self.import_from_source(&provider).await
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ mutable borrow occurs here
Check failure on line 46 in src/commands/init/mod.rs
github-actions / clippy
missing lifetime specifier
error[E0106]: missing lifetime specifier
--> src/commands/init/mod.rs:46:13
|
46 | Packwiz(FileProvider),
| ^^^^^^^^^^^^ expected named lifetime parameter
|
help: consider introducing a named lifetime parameter
|
43 ~ pub enum InitType<'a> {
44 | Normal,
45 | MRPack(String),
46 ~ Packwiz(FileProvider<'a>),
|