Mark platform extension enums as #[non_exhaustive]

OS-defined sets and error enums in the platform crates can now gain
variants without a breaking change.
This commit is contained in:
Olivier Goffart
2026-07-28 14:30:09 +00:00
parent 37d8a503e4
commit 9c7e191407
7 changed files with 13 additions and 0 deletions

View File

@@ -22,6 +22,7 @@ pub enum DndState {
}
#[derive(Debug)]
#[non_exhaustive]
pub enum UriListParseError {
EmptyData,
InvalidUtf8(#[allow(dead_code)] Utf8Error),

View File

@@ -32,6 +32,7 @@ pub use dnd::{Selection, SelectionReader, SelectionType, UriListParseError};
/// [`_NET_WM_WINDOW_TYPE`](https://specifications.freedesktop.org/wm-spec/wm-spec-1.5.html).
#[derive(Debug, Default, Copy, Clone, PartialEq, Eq, Hash)]
#[cfg_attr(feature = "serde", derive(Serialize, Deserialize))]
#[non_exhaustive]
pub enum WindowType {
/// A desktop feature. This can include a single window containing desktop icons with the same
/// dimensions as the screen, allowing the desktop environment to have full control of the