containerd / ttrpc-rust

Rust implementation of ttrpc (GRPC for low-memory environments)
Apache License 2.0
197 stars 47 forks source link

clippy: fix warnings in rust 1.63 #155

Closed Tim-Zhang closed 2 years ago

Tim-Zhang commented 2 years ago

Fix following clippy warnings caused by new added clippy-rules in rust 1.63.

error: you are deriving `PartialEq` and can implement `Eq`
  --> src/proto.rs:31:39
   |
31 | #[derive(Default, Debug, Clone, Copy, PartialEq)]
   |                                       ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
   |
   = note: `-D clippy::derive-partial-eq-without-eq` implied by `-D warnings`
   = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq

error: you are deriving `PartialEq` and can implement `Eq`
   --> src/asynchronous/stream.rs:323:30
    |
323 | #[derive(Clone, Copy, Debug, PartialEq)]
    |                              ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq

error: could not compile `ttrpc` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
error: could not compile `ttrpc` due to 2 previous errors
make: *** [Makefile:29: check] Error 101
Error: Process completed with exit code 2.
codecov[bot] commented 2 years ago

Codecov Report

Merging #155 (4f1e5f1) into master (005d131) will decrease coverage by 0.02%. The diff coverage is 22.22%.

@@            Coverage Diff             @@
##           master     #155      +/-   ##
==========================================
- Coverage   26.02%   26.00%   -0.03%     
==========================================
  Files          16       16              
  Lines        2413     2415       +2     
==========================================
  Hits          628      628              
- Misses       1785     1787       +2     
Impacted Files Coverage Δ
src/asynchronous/stream.rs 0.00% <0.00%> (ø)
src/proto.rs 90.16% <66.66%> (ø)

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.