Skip to content

Commit c921048

Browse files
authored
Merge pull request #2 from tathanhdinh/exhaustive_rust_enum
Disable non_exhaustive for Rust enums
2 parents 96efd8d + dea90e2 commit c921048

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,4 +13,4 @@ license = "GPL-3.0-only"
1313
[dependencies]
1414

1515
[build-dependencies]
16-
bindgen = "0.49.2"
16+
bindgen = "0.49.3"

build.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ fn main() {
1616
// and functions only.
1717
.whitelist_function("xc_.*")
1818
// Keep C's enums as Rust's enums.
19-
.default_enum_style(bindgen::EnumVariation::Rust)
19+
.default_enum_style(bindgen::EnumVariation::Rust { non_exhaustive: false })
2020
// Finish the builder and generate the bindings.
2121
.generate()
2222
// Unwrap the Result and panic on failure.

0 commit comments

Comments
 (0)