gschup / ggrs

GGRS is a reimagination of GGPO, enabling P2P rollback networking in Rust. Rollback to the future!
Other
507 stars 25 forks source link

Crate doesn't build after `cargo update`: `E0277` #72

Closed johanhelsing closed 5 months ago

johanhelsing commented 5 months ago

To Reproduce

git clone https://github.com/gschup/ggrs
cargo check
ggrs main cargo check
    Checking ggrs v0.10.1 (J:\dev\ggrs)
error[E0277]: the size for values of type `dyn StdError + Send + Sync` cannot be known at compilation time
  --> src\network\compression.rs:37:41
   |
37 |     let buf = bitfield_rle::decode(data)?;
   |                                         ^ doesn't have a size known at compile-time
   |
   = help: the trait `Sized` is not implemented for `dyn StdError + Send + Sync`, which is required by `Result<Vec<Vec<u8>>, Box<dyn StdError>>: FromResidual<Result<Infallible, Box<dyn StdError + Send + Sync>>>`
   = help: the following other types implement trait `FromResidual<R>`:
             <Result<T, F> as FromResidual<Yeet<E>>>
             <Result<T, F> as FromResidual<Result<Infallible, E>>>
   = note: required for `Box<dyn StdError + Send + Sync>` to implement `StdError`
   = note: required for `Box<dyn StdError>` to implement `From<Box<dyn StdError + Send + Sync>>`
   = note: required for `Result<Vec<Vec<u8>>, Box<dyn StdError>>` to implement `FromResidual<Result<Infallible, Box<dyn StdError + Send + Sync>>>`

For more information about this error, try `rustc --explain E0277`.

Expected behavior No errors

Desktop (please complete the following information):

MaxCWhitehead commented 5 months ago

@johanhelsing This PR should resolve the issue (though perhaps PR should be updated to also pin bitfield-rle version).

https://github.com/gschup/ggrs/pull/73

gschup commented 5 months ago

Fixed!