Skip to content

Commit

Permalink
Clean up edition move & clippy warnings (#691)
Browse files Browse the repository at this point in the history
  • Loading branch information
LucioFranco authored Jul 29, 2022
1 parent e744211 commit b314e84
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 5 deletions.
3 changes: 2 additions & 1 deletion prost-build/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ repository = "https://github.com/tokio-rs/prost"
documentation = "https://docs.rs/prost-build"
readme = "README.md"
description = "A Protocol Buffers implementation for the Rust Language."
edition = "2018"
edition = "2021"
rust-version = "1.56"

[features]
default = []
Expand Down
2 changes: 1 addition & 1 deletion prost-build/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
#![doc(html_root_url = "https://docs.rs/prost-build/0.10.1")]
#![allow(clippy::option_as_ref_deref)]
#![allow(clippy::option_as_ref_deref, clippy::format_push_string)]

//! `prost-build` compiles `.proto` files into Rust.
//!
Expand Down
3 changes: 2 additions & 1 deletion prost-derive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ repository = "https://github.com/tokio-rs/prost"
documentation = "https://docs.rs/prost-derive"
readme = "README.md"
description = "A Protocol Buffers implementation for the Rust Language."
edition = "2018"
edition = "2021"
rust-version = "1.56"

[lib]
proc_macro = true
Expand Down
3 changes: 2 additions & 1 deletion prost-types/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,8 @@ repository = "https://github.com/tokio-rs/prost"
documentation = "https://docs.rs/prost-types"
readme = "README.md"
description = "A Protocol Buffers implementation for the Rust Language."
edition = "2018"
edition = "2021"
rust-version = "1.56"

[lib]
doctest = false
Expand Down
2 changes: 1 addition & 1 deletion prost-types/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -372,7 +372,7 @@ impl TryFrom<Timestamp> for std::time::SystemTime {
timestamp
.seconds
.checked_neg()
.ok_or(TimestampError::OutOfSystemRange(timestamp.clone()))?
.ok_or_else(|| TimestampError::OutOfSystemRange(timestamp.clone()))?
as u64,
))
};
Expand Down

0 comments on commit b314e84

Please sign in to comment.