changelog: [`expl_impl_clone_on_copy`]: honor `allow`/`expect`
attributes on both the type declaration and the `impl`
Fixesrust-lang/rust-clippy#15842
r? @blyxyas
changelog: [`unnecessary_option_map_or_else`]: Added lint
unnecessary_option_map_or_else. As suggested in the issue description,
the implementation takes as reference the issue
rust-lang/rust-clippy#7328. The tests for lints `option_if_let_else` and
`or_fun_call` needed to be adjusted to comply with new lint.
fixesrust-lang/rust-clippy#14588
Fixesrust-lang/rust-clippy#15805
ICE bisects to 9457d640b7, which handles the span incorrectly when part
of the path originates from internal declarative macro.
changelog: none
Volatile reads and writes to non-primitive types are not well-defined,
and can cause problems.
Fixesrust-lang/rust-clippy#15529
changelog: [`volatile_composites`]: Lint when read/write_volatile is
used on composite types
(structs, arrays, etc) as their semantics are not well defined.
now lints on
```rs
let mut x = [1,2,3].into_iter();
loop {
let Some(x) = x.next() else { break };
dbg!(x);
}
```
```
changelog: [`while_let_loop`]: extend to lint on `let else`
```
Some lints had a wrong deprecated version on the documentation (I didn't
check all of them, just recent ones).
Fixesrust-lang/rust-clippy#15811
changelog: [`match_on_vec_items`]: Fixed the deprecation version to
"1.88.0"
changelog: [`option_map_or_err_ok `]: Fixed the deprecation version to
"1.87.0"
changelog: [`string_to_string `]: Fixed the deprecation version to
"1.91.0"
- cast `&[Arm]` to `&[Arm; 2]` early on to hopefully avoid bounds checks
- use `if let [pattern] = X { .. }` instead of `if let patterns = X {
let pattern = patterns[0]; .. }`
- use `Symbol`s instead of `&str`s
- reduce indentation
Diff best viewed with whitespace ignored
changelog: none
First commit treats all constants containing a macro call as non-local
and renames `eval_simple` to be a little clearer.
Second commit removes `CoreConstant` and treats most of them as though
they were local. A couple of the constants like `usize::MAX` are treated
as non-local as different targets may have different values.
`const_is_empty` will now ignore non-local constants since there's no
guarantee that they are the same across all targets/features/versions.
The third commit just changes some `eval` calls to `eval_local`. Most of
these were style lints which shouldn't be assuming the value of a
constant won't ever change.
changelog: none