refactor: mark public enums as non-exhaustive to improve API stability

Apply the #[non-exhaustive] attribute to ClientError and WarningKind to prevent breaking changes when adding new variants. Handle the catch-all case in the CLI formatter.
This commit is contained in:
Nils Andreas Svee committed 2026-05-11 12:33:40 +07:00
1 parent 8d1d0f50de
commit 21bc7805f7
3 files changed
+3

No files matched your search

+1
View File
@@ -3,6 +3,7 @@ use std::{io, time::Duration};
use thiserror::Error;
#[derive(Debug, Error)]
#[non_exhaustive]
pub enum ClientError {
#[error("failed to resolve server address {addr:?}")]
Resolve { addr: String },