summaryrefslogtreecommitdiff
path: root/bindgen-cli/options.rs
diff options
context:
space:
mode:
Diffstat (limited to 'bindgen-cli/options.rs')
-rw-r--r--bindgen-cli/options.rs7
1 files changed, 7 insertions, 0 deletions
diff --git a/bindgen-cli/options.rs b/bindgen-cli/options.rs
index 426e5cf7..f7fccc4f 100644
--- a/bindgen-cli/options.rs
+++ b/bindgen-cli/options.rs
@@ -562,6 +562,9 @@ where
.value_name("override")
.multiple_occurrences(true)
.number_of_values(1),
+ Arg::new("wrap-unsafe-ops")
+ .long("wrap-unsafe-ops")
+ .help("Wrap unsafe operations in unsafe blocks."),
Arg::new("V")
.long("version")
.help("Prints the version, and exits"),
@@ -1085,5 +1088,9 @@ where
}
}
+ if matches.is_present("wrap-unsafe-ops") {
+ builder = builder.wrap_unsafe_ops(true);
+ }
+
Ok((builder, output, verbose))
}