Skip to content

Added Debug and Display to ByteBuf #3

Added Debug and Display to ByteBuf

Added Debug and Display to ByteBuf #3

GitHub Actions / clippy succeeded Nov 21, 2023 in 0s

clippy

12 warnings

Details

Results

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

Versions

  • rustc 1.74.0 (79e9716c9 2023-11-13)
  • cargo 1.74.0 (ecb9851af 2023-10-18)
  • clippy 0.1.74 (79e9716 2023-11-13)

Annotations

Check warning on line 279 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

match expression looks like `matches!` macro

warning: match expression looks like `matches!` macro
   --> src/bytes.rs:276:12
    |
276 |           Ok(match u8::read_from_be(src)? {
    |  ____________^
277 | |             0 => false,
278 | |             _ => true
279 | |         })
    | |_________^ help: try: `!matches!(u8::read_from_be(src)?, 0)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro

Check warning on line 272 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

match expression looks like `matches!` macro

warning: match expression looks like `matches!` macro
   --> src/bytes.rs:269:12
    |
269 |           Ok(match u8::read_from_le(src)? {
    |  ____________^
270 | |             0 => false,
271 | |             _ => true
272 | |         })
    | |_________^ help: try: `!matches!(u8::read_from_le(src)?, 0)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro

Check warning on line 261 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:261:35
    |
261 |             false => dst.write_be(0 as u8)
    |                                   ^^^^^^^ help: try: `0_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 260 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:260:34
    |
260 |             true => dst.write_be(1 as u8),
    |                                  ^^^^^^^ help: try: `1_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 254 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:254:35
    |
254 |             false => dst.write_le(0 as u8)
    |                                   ^^^^^^^ help: try: `0_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 253 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:253:34
    |
253 |             true => dst.write_le(1 as u8),
    |                                  ^^^^^^^ help: try: `1_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 245 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

match expression looks like `matches!` macro

warning: match expression looks like `matches!` macro
   --> src/bytes.rs:242:9
    |
242 | /         match u8::read_bytes_be(bytes) {
243 | |             0 => false,
244 | |             _ => true
245 | |         }
    | |_________^ help: try: `!matches!(u8::read_bytes_be(bytes), 0)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro

Check warning on line 238 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

match expression looks like `matches!` macro

warning: match expression looks like `matches!` macro
   --> src/bytes.rs:235:9
    |
235 | /         match u8::read_bytes_le(bytes) {
236 | |             0 => false,
237 | |             _ => true
238 | |         }
    | |_________^ help: try: `!matches!(u8::read_bytes_le(bytes), 0)`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#match_like_matches_macro
    = note: `#[warn(clippy::match_like_matches_macro)]` on by default

Check warning on line 228 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:228:22
    |
228 |             false => (0 as u8).write_bytes_be(bytes)
    |                      ^^^^^^^^^ help: try: `0_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 227 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:227:21
    |
227 |             true => (1 as u8).write_bytes_be(bytes),
    |                     ^^^^^^^^^ help: try: `1_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 221 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:221:22
    |
221 |             false => (0 as u8).write_bytes_le(bytes)
    |                      ^^^^^^^^^ help: try: `0_u8`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast

Check warning on line 220 in src/bytes.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

casting integer literal to `u8` is unnecessary

warning: casting integer literal to `u8` is unnecessary
   --> src/bytes.rs:220:21
    |
220 |             true => (1 as u8).write_bytes_le(bytes),
    |                     ^^^^^^^^^ help: try: `1_u8`
    |
    = 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