dropbox / pb-jelly

A protobuf code generation framework for the Rust language developed at Dropbox.
Apache License 2.0
610 stars 25 forks source link

Fix for non-optional Box'ed messages #83

Closed ParkMyCar closed 3 years ago

ParkMyCar commented 3 years ago

Daniel stumbled across this bug where a non-optional boxed messages (Box<T: Message>) don't compile, unfortunately it also threw a pretty non-descriptive error because of the bounds we have on the generic impl of Message. The fix is to de-reference non-optional boxed messages like we de-reference optional boxed messages (Option<Box<T: Message>>). I also added a field in the box_it example of this.

ParkMyCar commented 3 years ago

It looks like the CI failure was because the Linux build failed to setup, Windows and macOS pass.

ParkMyCar commented 3 years ago

Added a test in #84