Skip to content

Moved quality definition out of if statement to reduce repeated code.… #272

Moved quality definition out of if statement to reduce repeated code.…

Moved quality definition out of if statement to reduce repeated code.… #272

GitHub Actions / clippy succeeded Jan 27, 2025 in 0s

clippy

29 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 29
Note 0
Help 0

Versions

  • rustc 1.86.0-nightly (f85c6de55 2025-01-26)
  • cargo 1.86.0-nightly (cecde95c1 2025-01-24)
  • clippy 0.1.86 (f85c6de552 2025-01-26)

Annotations

Check warning on line 64 in src/ska_dict/bloom_filter.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
  --> src/ska_dict/bloom_filter.rs:63:9
   |
63 | /         1 << (key & 63)
64 | |             | 1 << ((key >> 6) & 63)
   | |____________________________________^ help: consider parenthesizing your expression: `(1 << (key & 63)) | (1 << ((key >> 6) & 63))`
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 65 in src/ska_dict/bloom_filter.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
  --> src/ska_dict/bloom_filter.rs:63:9
   |
63 | /         1 << (key & 63)
64 | |             | 1 << ((key >> 6) & 63)
65 | |             | 1 << ((key >> 12) & 63)
   | |_____________________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence
help: consider parenthesizing your expression
   |
63 ~         1 << (key & 63)
64 +             | 1 << ((key >> 6) & 63) | (1 << ((key >> 12) & 63))
   |

Check warning on line 66 in src/ska_dict/bloom_filter.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
  --> src/ska_dict/bloom_filter.rs:63:9
   |
63 | /         1 << (key & 63)
64 | |             | 1 << ((key >> 6) & 63)
65 | |             | 1 << ((key >> 12) & 63)
66 | |             | 1 << ((key >> 18) & 63)
   | |_____________________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence
help: consider parenthesizing your expression
   |
63 ~         1 << (key & 63)
64 +             | 1 << ((key >> 6) & 63)
65 +             | 1 << ((key >> 12) & 63) | (1 << ((key >> 18) & 63))
   |

Check warning on line 67 in src/ska_dict/bloom_filter.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
  --> src/ska_dict/bloom_filter.rs:63:9
   |
63 | /         1 << (key & 63)
64 | |             | 1 << ((key >> 6) & 63)
65 | |             | 1 << ((key >> 12) & 63)
66 | |             | 1 << ((key >> 18) & 63)
67 | |             | 1 << ((key >> 24) & 63)
   | |_____________________________________^
   |
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence
help: consider parenthesizing your expression
   |
63 ~         1 << (key & 63)
64 +             | 1 << ((key >> 6) & 63)
65 +             | 1 << ((key >> 12) & 63)
66 +             | 1 << ((key >> 18) & 63) | (1 << ((key >> 24) & 63))
   |

Check warning on line 200 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:200:17
    |
200 |         self = (self >> 64 & 0x0000000000000000FFFFFFFFFFFFFFFF)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 64) & 0x0000000000000000FFFFFFFFFFFFFFFF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 201 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:200:16
    |
200 |           self = (self >> 64 & 0x0000000000000000FFFFFFFFFFFFFFFF)
    |  ________________^
201 | |             | (self & 0x0000000000000000FFFFFFFFFFFFFFFF) << 64;
    | |_______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 64 & 0x0000000000000000FFFFFFFFFFFFFFFF) | ((self & 0x0000000000000000FFFFFFFFFFFFFFFF) << 64)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 198 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:198:17
    |
198 |         self = (self >> 32 & 0x00000000FFFFFFFF00000000FFFFFFFF)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 32) & 0x00000000FFFFFFFF00000000FFFFFFFF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 199 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:198:16
    |
198 |           self = (self >> 32 & 0x00000000FFFFFFFF00000000FFFFFFFF)
    |  ________________^
199 | |             | (self & 0x00000000FFFFFFFF00000000FFFFFFFF) << 32;
    | |_______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 32 & 0x00000000FFFFFFFF00000000FFFFFFFF) | ((self & 0x00000000FFFFFFFF00000000FFFFFFFF) << 32)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 196 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:196:17
    |
196 |         self = (self >> 16 & 0x0000FFFF0000FFFF0000FFFF0000FFFF)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 16) & 0x0000FFFF0000FFFF0000FFFF0000FFFF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 197 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:196:16
    |
196 |           self = (self >> 16 & 0x0000FFFF0000FFFF0000FFFF0000FFFF)
    |  ________________^
197 | |             | (self & 0x0000FFFF0000FFFF0000FFFF0000FFFF) << 16;
    | |_______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 16 & 0x0000FFFF0000FFFF0000FFFF0000FFFF) | ((self & 0x0000FFFF0000FFFF0000FFFF0000FFFF) << 16)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 194 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:194:17
    |
194 |         self = (self >> 8 & 0x00FF00FF00FF00FF00FF00FF00FF00FF)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 8) & 0x00FF00FF00FF00FF00FF00FF00FF00FF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 195 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:194:16
    |
194 |           self = (self >> 8 & 0x00FF00FF00FF00FF00FF00FF00FF00FF)
    |  ________________^
195 | |             | (self & 0x00FF00FF00FF00FF00FF00FF00FF00FF) << 8;
    | |______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 8 & 0x00FF00FF00FF00FF00FF00FF00FF00FF) | ((self & 0x00FF00FF00FF00FF00FF00FF00FF00FF) << 8)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 192 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:192:17
    |
192 |         self = (self >> 4 & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 4) & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 193 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:192:16
    |
192 |           self = (self >> 4 & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F)
    |  ________________^
193 | |             | (self & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F) << 4;
    | |______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 4 & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F) | ((self & 0x0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F0F) << 4)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 190 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:190:17
    |
190 |         self = (self >> 2 & 0x33333333333333333333333333333333)
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 2) & 0x33333333333333333333333333333333`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 191 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:190:16
    |
190 |           self = (self >> 2 & 0x33333333333333333333333333333333)
    |  ________________^
191 | |             | (self & 0x33333333333333333333333333333333) << 2;
    | |______________________________________________________________^ help: consider parenthesizing your expression: `(self >> 2 & 0x33333333333333333333333333333333) | ((self & 0x33333333333333333333333333333333) << 2)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 136 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:136:17
    |
136 |         self = (self >> 32 & 0x00000000FFFFFFFF) | (self & 0x00000000FFFFFFFF) << 32;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 32) & 0x00000000FFFFFFFF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 136 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:136:16
    |
136 |         self = (self >> 32 & 0x00000000FFFFFFFF) | (self & 0x00000000FFFFFFFF) << 32;
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 32 & 0x00000000FFFFFFFF) | ((self & 0x00000000FFFFFFFF) << 32)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 135 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:135:17
    |
135 |         self = (self >> 16 & 0x0000FFFF0000FFFF) | (self & 0x0000FFFF0000FFFF) << 16;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 16) & 0x0000FFFF0000FFFF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 135 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:135:16
    |
135 |         self = (self >> 16 & 0x0000FFFF0000FFFF) | (self & 0x0000FFFF0000FFFF) << 16;
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 16 & 0x0000FFFF0000FFFF) | ((self & 0x0000FFFF0000FFFF) << 16)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 134 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:134:17
    |
134 |         self = (self >> 8 & 0x00FF00FF00FF00FF) | (self & 0x00FF00FF00FF00FF) << 8;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 8) & 0x00FF00FF00FF00FF`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 134 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:134:16
    |
134 |         self = (self >> 8 & 0x00FF00FF00FF00FF) | (self & 0x00FF00FF00FF00FF) << 8;
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 8 & 0x00FF00FF00FF00FF) | ((self & 0x00FF00FF00FF00FF) << 8)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 133 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:133:17
    |
133 |         self = (self >> 4 & 0x0F0F0F0F0F0F0F0F) | (self & 0x0F0F0F0F0F0F0F0F) << 4;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 4) & 0x0F0F0F0F0F0F0F0F`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 133 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:133:16
    |
133 |         self = (self >> 4 & 0x0F0F0F0F0F0F0F0F) | (self & 0x0F0F0F0F0F0F0F0F) << 4;
    |                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 4 & 0x0F0F0F0F0F0F0F0F) | ((self & 0x0F0F0F0F0F0F0F0F) << 4)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence

Check warning on line 132 in src/ska_dict/bit_encoding.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

operator precedence can trip the unwary

warning: operator precedence can trip the unwary
   --> src/ska_dict/bit_encoding.rs:132:17
    |
132 |         self = (self >> 2 & 0x3333333333333333) | (self & 0x3333333333333333) << 2;
    |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider parenthesizing your expression: `(self >> 2) & 0x3333333333333333`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#precedence