2019-12-06 12:45:33 -06:00
|
|
|
error: mutable key type
|
2023-07-17 03:19:29 -05:00
|
|
|
--> $DIR/mut_key.rs:31:32
|
2019-12-06 12:45:33 -06:00
|
|
|
|
|
|
|
|
LL | fn should_not_take_this_arg(m: &mut HashMap<Key, usize>, _n: usize) -> HashSet<Key> {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
2021-07-01 11:17:38 -05:00
|
|
|
= note: `-D clippy::mutable-key-type` implied by `-D warnings`
|
2023-08-01 07:02:21 -05:00
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::mutable_key_type)]`
|
2019-12-06 12:45:33 -06:00
|
|
|
|
|
|
|
error: mutable key type
|
2023-07-17 03:19:29 -05:00
|
|
|
--> $DIR/mut_key.rs:31:72
|
2019-12-06 12:45:33 -06:00
|
|
|
|
|
|
|
|
LL | fn should_not_take_this_arg(m: &mut HashMap<Key, usize>, _n: usize) -> HashSet<Key> {
|
|
|
|
| ^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:37:5
|
2019-12-06 12:45:33 -06:00
|
|
|
|
|
|
|
|
LL | let _other: HashMap<Key, bool> = HashMap::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2020-01-16 17:18:37 -06:00
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:65:22
|
2020-01-16 17:18:37 -06:00
|
|
|
|
|
|
|
|
LL | fn tuples_bad<U>(_m: &mut HashMap<(Key, U), bool>) {}
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2021-09-28 12:03:12 -05:00
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:78:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Cell<usize>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:80:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<&mut Cell<usize>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:82:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<&mut usize, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:85:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Vec<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:87:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<BTreeMap<Cell<usize>, ()>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:89:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<BTreeMap<(), Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:91:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<BTreeSet<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:93:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Option<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:95:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Option<Vec<Cell<usize>>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:97:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Result<&mut usize, ()>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:100:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Box<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:102:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Rc<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
|
|
|
error: mutable key type
|
2023-08-24 14:32:12 -05:00
|
|
|
--> $DIR/mut_key.rs:104:5
|
2021-09-28 12:03:12 -05:00
|
|
|
|
|
|
|
|
LL | let _map = HashMap::<Arc<Cell<usize>>, usize>::new();
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
|
|
|
|
|
2023-07-31 16:53:53 -05:00
|
|
|
error: this argument is a mutable reference, but not used mutably
|
|
|
|
--> $DIR/mut_key.rs:31:32
|
|
|
|
|
|
|
|
|
LL | fn should_not_take_this_arg(m: &mut HashMap<Key, usize>, _n: usize) -> HashSet<Key> {
|
|
|
|
| ^^^^^^^^^^^^^^^^^^^^^^^^ help: consider changing to: `&HashMap<Key, usize>`
|
|
|
|
|
|
|
|
|
= note: `-D clippy::needless-pass-by-ref-mut` implied by `-D warnings`
|
2023-08-01 07:02:21 -05:00
|
|
|
= help: to override `-D warnings` add `#[allow(clippy::needless_pass_by_ref_mut)]`
|
2023-07-31 16:53:53 -05:00
|
|
|
|
2023-07-17 03:19:29 -05:00
|
|
|
error: aborting due to 18 previous errors
|
2019-12-06 12:45:33 -06:00
|
|
|
|