Skip to content

Commit

Permalink
feat(stmt)!: mark statement as non-exhaustive
Browse files Browse the repository at this point in the history
non-exhaustive avoids future breaking changes when statements are added
by forcing users to add a wildcard arm to match on statement.
  • Loading branch information
jwhb committed Oct 21, 2024
1 parent ae6d307 commit 8751202
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/stmt.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ use crate::expr::Expression;

#[derive(Debug, Clone, Eq, PartialEq, Serialize, Deserialize)]
#[serde(rename_all = "lowercase")]
#[non_exhaustive]
/// Statements are the building blocks for rules. Each rule consists of at least one.
///
/// See <https://manpages.debian.org/testing/libnftables1/libnftables-json.5.en.html#STATEMENTS>.
Expand Down

0 comments on commit 8751202

Please sign in to comment.