Move core to workspace crate rune-core #55
clippy
30 errors, 1 warning
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 30 |
Warning | 1 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.74.1 (a28077b28 2023-12-04)
- cargo 1.74.1 (ecb9851af 2023-10-18)
- clippy 0.1.74 (a28077b 2023-12-04)
Annotations
Check failure on line 1296 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:1296:51
|
1296 | matches!(self.untag(), Object::Symbol(sym::TRUE))
| ^^^ use of undeclared crate or module `sym`
Check failure on line 1298 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:1298:51
|
1298 | matches!(self.untag(), Object::Symbol(sym::NIL))
| ^^^ use of undeclared crate or module `sym`
Check failure on line 1423 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
cannot find function `nil` in this scope
error[E0425]: cannot find function `nil` in this scope
--> crates/rune-core/src/object/tagged.rs:1423:26
|
1423 | List::Nil => nil(),
| ^^^ not found in this scope
Check failure on line 1311 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
cannot find function `nil` in this scope
error[E0425]: cannot find function `nil` in this scope
--> crates/rune-core/src/object/tagged.rs:1311:9
|
1311 | nil()
| ^^^ not found in this scope
Check failure on line 1158 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:1158:17
|
1158 | self == sym::NIL
| ^^^ use of undeclared crate or module `sym`
Check failure on line 967 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:967:54
|
967 | pub const TRUE: Object<'static> = Object::Symbol(sym::TRUE);
| ^^^ use of undeclared crate or module `sym`
Check failure on line 966 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:966:53
|
966 | pub const NIL: Object<'static> = Object::Symbol(sym::NIL);
| ^^^ use of undeclared crate or module `sym`
Check failure on line 881 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
cannot find function `nil` in this scope
error[E0425]: cannot find function `nil` in this scope
--> crates/rune-core/src/object/tagged.rs:881:26
|
881 | unsafe { cast_gc(nil()) }
| ^^^ not found in this scope
Check failure on line 490 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:490:58
|
490 | List::Nil => unsafe { cast_gc(TaggedPtr::tag(sym::NIL)) },
| ^^^ use of undeclared crate or module `sym`
Check failure on line 229 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
failed to resolve: use of undeclared crate or module `sym`
error[E0433]: failed to resolve: use of undeclared crate or module `sym`
--> crates/rune-core/src/object/tagged.rs:229:37
|
229 | unsafe { Self::Out::tag_ptr(sym::NIL.get_ptr()) }
| ^^^ use of undeclared crate or module `sym`
Check failure on line 200 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
cannot find function `nil` in this scope
error[E0425]: cannot find function `nil` in this scope
--> crates/rune-core/src/object/tagged.rs:200:21
|
200 | None => nil(),
| ^^^ not found in this scope
Check failure on line 37 in crates/rune-core/src/object/tagged.rs
github-actions / clippy
cannot find function `nil` in this scope
error[E0425]: cannot find function `nil` in this scope
--> crates/rune-core/src/object/tagged.rs:37:21
|
37 | Self { ptr: nil().ptr }
| ^^^ not found in this scope
Check failure on line 112 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `truncate` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `truncate` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:112:14
|
112 | self.truncate(offset + 1);
| ^^^^^^^^ method not found in `&mut RootedLispStack`
|
help: one of the expressions' fields has a method of the same name
|
112 | self.frame_starts.truncate(offset + 1);
| +++++++++++++
Check failure on line 105 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `push` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `push` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:105:18
|
105 | self.push(nil());
| ^^^^
|
help: one of the expressions' fields has a method of the same name
|
105 | self.frame_starts.push(nil());
| +++++++++++++
help: there is a method with a similar name
|
105 | self.push_ref(nil());
| ~~~~~~~~
Check failure on line 100 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `swap_remove` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `swap_remove` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:100:14
|
100 | self.swap_remove(index);
| ^^^^^^^^^^^ method not found in `&mut RootedLispStack`
|
help: one of the expressions' fields has a method of the same name
|
100 | self.frame_starts.swap_remove(index);
| +++++++++++++
Check failure on line 95 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `push` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `push` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:95:14
|
95 | self.push(obj);
| ^^^^
|
help: one of the expressions' fields has a method of the same name
|
95 | self.frame_starts.push(obj);
| +++++++++++++
help: there is a method with a similar name
|
95 | self.push_ref(obj);
| ~~~~~~~~
Check failure on line 88 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:88:29
|
88 | let from_end = self.len() - (i + 1);
| ^^^ method not found in `&RootedLispStack`
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item `len`, perhaps you need to implement it:
candidate #1: `std::iter::ExactSizeIterator`
help: one of the expressions' fields has a method of the same name
|
88 | let from_end = self.frame_starts.len() - (i + 1);
| +++++++++++++
Check failure on line 87 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:87:26
|
87 | assert!(i < self.len());
| ^^^ method not found in `&RootedLispStack`
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item `len`, perhaps you need to implement it:
candidate #1: `std::iter::ExactSizeIterator`
help: one of the expressions' fields has a method of the same name
|
87 | assert!(i < self.frame_starts.len());
| +++++++++++++
Check failure on line 83 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `last_mut` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `last_mut` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:83:14
|
83 | self.last_mut().unwrap()
| ^^^^^^^^ method not found in `&mut RootedLispStack`
|
help: one of the expressions' fields has a method of the same name
|
83 | self.frame_starts.last_mut().unwrap()
| +++++++++++++
Check failure on line 79 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `bind_mut` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `bind_mut` found for mutable reference `&mut env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:79:14
|
79 | self.bind_mut(cx).pop().unwrap()
| ^^^^^^^^ method not found in `&mut RootedLispStack`
Check failure on line 68 in crates/rune-core/src/env/stack.rs
github-actions / clippy
the method `len` exists for mutable reference `&mut RootedLispStack`, but its trait bounds were not satisfied
error[E0599]: the method `len` exists for mutable reference `&mut RootedLispStack`, but its trait bounds were not satisfied
--> crates/rune-core/src/env/stack.rs:68:31
|
10 | #[derive(Debug, Default, Trace)]
| ----- doesn't satisfy `_: ExactSizeIterator`
...
68 | assert!(start <= self.len());
| ^^^ method cannot be called on `&mut RootedLispStack` due to unsatisfied trait bounds
|
= note: the following trait bounds were not satisfied:
`env::stack::RootedLispStack: std::iter::ExactSizeIterator`
which is required by `&mut env::stack::RootedLispStack: std::iter::ExactSizeIterator`
note: the trait `std::iter::ExactSizeIterator` must be implemented
--> /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/core/src/iter/traits/exact_size.rs:86:1
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item `len`, perhaps you need to implement it:
candidate #1: `std::iter::ExactSizeIterator`
Check failure on line 60 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:60:24
|
60 | let end = self.len() - index.end;
| ^^^ method not found in `&RootedLispStack`
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item `len`, perhaps you need to implement it:
candidate #1: `std::iter::ExactSizeIterator`
help: one of the expressions' fields has a method of the same name
|
60 | let end = self.frame_starts.len() - index.end;
| +++++++++++++
Check failure on line 59 in crates/rune-core/src/env/stack.rs
github-actions / clippy
no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
error[E0599]: no method named `len` found for reference `&env::stack::RootedLispStack` in the current scope
--> crates/rune-core/src/env/stack.rs:59:35
|
59 | assert!(index.end <= self.len());
| ^^^ method not found in `&RootedLispStack`
|
= help: items from traits can only be used if the trait is implemented and in scope
= note: the following trait defines an item `len`, perhaps you need to implement it:
candidate #1: `std::iter::ExactSizeIterator`
help: one of the expressions' fields has a method of the same name
|
59 | assert!(index.end <= self.frame_starts.len());
| +++++++++++++
Check failure on line 64 in crates/rune-core/src/error.rs
github-actions / clippy
mismatched types
error[E0308]: mismatched types
--> crates/rune-core/src/error.rs:64:29
|
64 | self.backtrace.push(format!("{name} {display}").into_boxed_str());
| ---- ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ expected `String`, found `Box<str>`
| |
| arguments to this method are incorrect
|
= note: expected struct `std::string::String`
found struct `std::boxed::Box<str>`
note: method defined here
--> /rustc/a28077b28a02b92985b3a3faecf92813155f1ea1/library/alloc/src/vec/mod.rs:1878:12
help: try removing the method call
|
64 - self.backtrace.push(format!("{name} {display}").into_boxed_str());
64 + self.backtrace.push(format!("{name} {display}"));
|
Check failure on line 59 in crates/rune-core/src/error.rs
github-actions / clippy
mismatched types
error[E0308]: mismatched types
--> crates/rune-core/src/error.rs:59:32
|
59 | Self { backtrace: vec![trace], error: ErrorType::Err(error) }
| ^^^^^- help: try using a conversion method: `.to_string()`
| |
| expected `String`, found `Box<str>`
|
= note: expected struct `std::string::String`
found struct `std::boxed::Box<str>`