summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--.travis.yml7
-rw-r--r--book/src/cpp.md6
-rw-r--r--src/lib.rs2
-rw-r--r--src/options.rs4
4 files changed, 9 insertions, 10 deletions
diff --git a/.travis.yml b/.travis.yml
index 1e813229..ee3f970b 100644
--- a/.travis.yml
+++ b/.travis.yml
@@ -1,12 +1,5 @@
language: rust
-addons:
- apt:
- sources:
- - ubuntu-toolchain-r-test
- packages:
- - gcc-5
-
os:
- linux
diff --git a/book/src/cpp.md b/book/src/cpp.md
index d181dec4..03249016 100644
--- a/book/src/cpp.md
+++ b/book/src/cpp.md
@@ -65,3 +65,9 @@ cannot translate into Rust:
* Automatically calling copy and/or move constructors or destructors. Supporting
this isn't possible with Rust's move semantics.
+
+* Exceptions: if a function called through a `bindgen`-generated interface
+ raises an exception that is not caught by the function itself, this will
+ generate undefined behaviour. See
+ [the tracking issue for exceptions](https://github.com/rust-lang-nursery/rust-bindgen/issues/1208)
+ for more details.
diff --git a/src/lib.rs b/src/lib.rs
index 934cf617..e2dbf8b5 100644
--- a/src/lib.rs
+++ b/src/lib.rs
@@ -1609,7 +1609,7 @@ impl Bindings {
if let Some(h) = options.input_header.as_ref() {
if let Ok(md) = std::fs::metadata(h) {
- if !md.is_file() {
+ if md.is_dir() {
eprintln!("error: '{}' is a folder", h);
return Err(());
}
diff --git a/src/options.rs b/src/options.rs
index 10c31234..c35aa276 100644
--- a/src/options.rs
+++ b/src/options.rs
@@ -237,9 +237,9 @@ where
.help("Generate inline functions."),
Arg::with_name("whitelist-type")
.long("whitelist-type")
- .help("Whitelist the type. Other non-whitelisted types will \
+ .help("Only generate types matching <regex>. Other non-whitelisted types will \
not be generated.")
- .value_name("type")
+ .value_name("regex")
.takes_value(true)
.multiple(true)
.number_of_values(1),