From 66a23cafbd8c69cc1618015a5744beb5cc5c4c1d Mon Sep 17 00:00:00 2001 From: Wil Carmon Date: Wed, 18 Sep 2024 18:48:21 -0400 Subject: [PATCH] Update protobuf.rs allow duration comparisons (similar to chrono::TimeDelta, which has the same structure) https://docs.rs/chrono/latest/src/chrono/time_delta.rs.html#52 --- prost-types/src/protobuf.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/prost-types/src/protobuf.rs b/prost-types/src/protobuf.rs index 6f75dfc2b..25035273f 100644 --- a/prost-types/src/protobuf.rs +++ b/prost-types/src/protobuf.rs @@ -1815,7 +1815,7 @@ pub struct Mixin { /// encoded in JSON format as "3s", while 3 seconds and 1 nanosecond should /// be expressed in JSON format as "3.000000001s", and 3 seconds and 1 /// microsecond should be expressed in JSON format as "3.000001s". -#[derive(Clone, Copy, PartialEq, ::prost::Message)] +#[derive(Clone, Copy, PartialEq, PartialOrd, ::prost::Message)] pub struct Duration { /// Signed seconds of the span of time. Must be from -315,576,000,000 /// to +315,576,000,000 inclusive. Note: these bounds are computed from: