Skip to content

(from a contributor) - Hamming distance: count_ones and count_zeros #16

(from a contributor) - Hamming distance: count_ones and count_zeros

(from a contributor) - Hamming distance: count_ones and count_zeros #16

Triggered via pull request May 31, 2024 06:14
Status Failure
Total duration 2m 5s
Artifacts

rust.yml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

1 error and 42 warnings
fmt
The process '/home/runner/.cargo/bin/cargo' failed with exit code 1
fmt
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
fmt
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
fmt
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
build
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
build
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
docs
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2, actions-rs/toolchain@v1, swatinem/rust-cache@v1, actions-rs/cargo@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
docs
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, swatinem/rust-cache@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
docs
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `save-state` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
docs
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
useless use of `vec!`: src/lib.rs#L2592
warning: useless use of `vec!` --> src/lib.rs:2592:21 | 2592 | let bools = vec![true, false, true, true]; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `[true, false, true, true]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec
useless use of `vec!`: src/lib.rs#L2110
warning: useless use of `vec!` --> src/lib.rs:2110:21 | 2110 | let bools = vec![true, false, true, true]; | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `[true, false, true, true]` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec = note: `#[warn(clippy::useless_vec)]` on by default
casting integer literal to `u64` is unnecessary: src/lib.rs#L2718
warning: casting integer literal to `u64` is unnecessary --> src/lib.rs:2718:24 | 2718 | assert_eq!(0 as u64, tbits.count_zeros()); | ^^^^^^^^ help: try: `0_u64` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
casting integer literal to `u64` is unnecessary: src/lib.rs#L2700
warning: casting integer literal to `u64` is unnecessary --> src/lib.rs:2700:24 | 2700 | assert_eq!(0 as u64, f.count_ones()); | ^^^^^^^^ help: try: `0_u64` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast = note: `#[warn(clippy::unnecessary_cast)]` on by default
used `assert_eq!` with a literal bool: src/lib.rs#L2405
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2405:9 | 2405 | assert_eq!(s[5 * U32_BITS + 2], true); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2405 - assert_eq!(s[5 * U32_BITS + 2], true); 2405 + assert!(s[5 * U32_BITS + 2]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2404
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2404:9 | 2404 | assert_eq!(s[5 * U32_BITS + 1], false); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2404 - assert_eq!(s[5 * U32_BITS + 1], false); 2404 + assert!(!s[5 * U32_BITS + 1]); |
this operation has no effect: src/lib.rs#L2403
warning: this operation has no effect --> src/lib.rs:2403:22 | 2403 | assert_eq!(s[5 * U32_BITS - 0], true); | ^^^^^^^^^^^^^^^^ help: consider reducing it to: `5 * U32_BITS` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#identity_op = note: `#[warn(clippy::identity_op)]` on by default
used `assert_eq!` with a literal bool: src/lib.rs#L2403
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2403:9 | 2403 | assert_eq!(s[5 * U32_BITS - 0], true); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2403 - assert_eq!(s[5 * U32_BITS - 0], true); 2403 + assert!(s[5 * U32_BITS - 0]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2402
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2402:9 | 2402 | assert_eq!(s[5 * U32_BITS - 1], true); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2402 - assert_eq!(s[5 * U32_BITS - 1], true); 2402 + assert!(s[5 * U32_BITS - 1]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2353
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2353:9 | 2353 | assert_eq!(s[5 * U32_BITS + 1], false); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2353 - assert_eq!(s[5 * U32_BITS + 1], false); 2353 + assert!(!s[5 * U32_BITS + 1]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2351
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2351:9 | 2351 | assert_eq!(s[5 * U32_BITS], false); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2351 - assert_eq!(s[5 * U32_BITS], false); 2351 + assert!(!s[5 * U32_BITS]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2348
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2348:9 | 2348 | assert_eq!(s[5 * U32_BITS - 1], true); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2348 - assert_eq!(s[5 * U32_BITS - 1], true); 2348 + assert!(s[5 * U32_BITS - 1]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2347
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2347:9 | 2347 | assert_eq!(s[5 * U32_BITS - 2], true); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison help: replace it with `assert!(..)` | 2347 - assert_eq!(s[5 * U32_BITS - 2], true); 2347 + assert!(s[5 * U32_BITS - 2]); |
used `assert_eq!` with a literal bool: src/lib.rs#L2344
warning: used `assert_eq!` with a literal bool --> src/lib.rs:2344:9 | 2344 | assert_eq!(s[5 * U32_BITS - 3], false); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison = note: `#[warn(clippy::bool_assert_comparison)]` on by default help: replace it with `assert!(..)` | 2344 - assert_eq!(s[5 * U32_BITS - 3], false); 2344 + assert!(!s[5 * U32_BITS - 3]); |
this is a decimal constant: src/lib.rs#L2657
warning: this is a decimal constant --> src/lib.rs:2657:34 | 2657 | assert_eq!(&[01, 00, 02, 03][..], &*a.to_bytes()); | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zero_prefixed_literal help: if you mean to use a decimal constant, remove the `0` to avoid confusion | 2657 | assert_eq!(&[01, 00, 02, 3][..], &*a.to_bytes()); | ~ help: if you mean to use an octal constant, use `0o` | 2657 | assert_eq!(&[01, 00, 02, 0o3][..], &*a.to_bytes()); | ~~~
this is a decimal constant: src/lib.rs#L2657
warning: this is a decimal constant --> src/lib.rs:2657:30 | 2657 | assert_eq!(&[01, 00, 02, 03][..], &*a.to_bytes()); | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zero_prefixed_literal help: if you mean to use a decimal constant, remove the `0` to avoid confusion | 2657 | assert_eq!(&[01, 00, 2, 03][..], &*a.to_bytes()); | ~ help: if you mean to use an octal constant, use `0o` | 2657 | assert_eq!(&[01, 00, 0o2, 03][..], &*a.to_bytes()); | ~~~
this is a decimal constant: src/lib.rs#L2657
warning: this is a decimal constant --> src/lib.rs:2657:22 | 2657 | assert_eq!(&[01, 00, 02, 03][..], &*a.to_bytes()); | ^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#zero_prefixed_literal = note: `#[warn(clippy::zero_prefixed_literal)]` on by default help: if you mean to use a decimal constant, remove the `0` to avoid confusion | 2657 | assert_eq!(&[1, 00, 02, 03][..], &*a.to_bytes()); | ~ help: if you mean to use an octal constant, use `0o` | 2657 | assert_eq!(&[0o1, 00, 02, 03][..], &*a.to_bytes()); | ~~~
clippy
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/clippy-check@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
clippy
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2, actions-rs/toolchain@v1, actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
clippy
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Miri
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v2. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
Miri
The following actions uses node12 which is deprecated and will be forced to run on node16: actions/checkout@v2. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/