Skip to content

Commit

Permalink
Derive Debug and eq. comparison traits for InvalidRustTarget enum
Browse files Browse the repository at this point in the history
These traits are useful to get expressions like `RustTarget::stable(82,
0).unwrap()` to build, as `unwrap()` requires such a `Result` to
implement `Debug`. The equality comparison traits may also be useful in
cases where pattern matching the enum variants through e.g. `matches!`
or match expressions is deemed less stylish.
  • Loading branch information
AlexTMjugador authored and emilio committed Dec 13, 2024
1 parent 1cd618e commit 3e0094e
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions bindgen/features.rs
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ enum Version {
Nightly,
}

#[derive(Debug, PartialEq, Eq, Hash)]
pub enum InvalidRustTarget {
TooEarly,
}
Expand Down

0 comments on commit 3e0094e

Please sign in to comment.