summaryrefslogtreecommitdiff
path: root/bindgen/rust/celeritas-sys/build.rs
diff options
context:
space:
mode:
authoromniscient <17525998+omnisci3nce@users.noreply.github.com>2024-07-27 17:49:33 +1000
committeromniscient <17525998+omnisci3nce@users.noreply.github.com>2024-07-27 17:49:33 +1000
commit02fe2c010857e6c3734b3a354c4119f799947fc6 (patch)
treef6286df45e678929e4998dbfe9d770c58228fedd /bindgen/rust/celeritas-sys/build.rs
parentfb1778cb1c853f7fa48afffd256612eac6f387c8 (diff)
misc bindgen crate cleanup
Diffstat (limited to 'bindgen/rust/celeritas-sys/build.rs')
-rw-r--r--bindgen/rust/celeritas-sys/build.rs4
1 files changed, 2 insertions, 2 deletions
diff --git a/bindgen/rust/celeritas-sys/build.rs b/bindgen/rust/celeritas-sys/build.rs
index f7bf741..9eaa44f 100644
--- a/bindgen/rust/celeritas-sys/build.rs
+++ b/bindgen/rust/celeritas-sys/build.rs
@@ -3,7 +3,7 @@ use std::path::PathBuf;
use bindgen::callbacks::ParseCallbacks;
-const serializable_types: &[&'static str] = &[
+const SERIALIZABLE_TYPES: &[&'static str] = &[
"Vec2",
"Vec3",
"Vec4",
@@ -17,7 +17,7 @@ const serializable_types: &[&'static str] = &[
struct DeriveSerialize;
impl ParseCallbacks for DeriveSerialize {
fn add_derives(&self, info: &bindgen::callbacks::DeriveInfo<'_>) -> Vec<String> {
- if (serializable_types.contains(&info.name)) {
+ if SERIALIZABLE_TYPES.contains(&info.name) {
vec!["Serialize".to_string(), "Deserialize".to_string()]
} else {
vec![]