From 2990a1c255185522a93d20421cae2d31080bfbab Mon Sep 17 00:00:00 2001 From: Floris Bruynooghe Date: Thu, 26 Dec 2019 22:33:48 +0100 Subject: [PATCH] Mark the ChatInfo struct non_exhaustive This is a new feature in Rust 1.40, it means users outside the crate will not be able to create these structs, allowing us to add fields without breaking the public API. --- src/chat.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/chat.rs b/src/chat.rs index 5d8807c23..6e28e8071 100644 --- a/src/chat.rs +++ b/src/chat.rs @@ -523,6 +523,7 @@ impl Chat { /// The current state of a chat. #[derive(Debug, Clone, PartialEq, Eq, Serialize, Deserialize)] +#[non_exhaustive] pub struct ChatInfo { /// The chat ID. pub id: u32,