diff options
author | Christian Poveda Ruiz <31802960+pvdrz@users.noreply.github.com> | 2022-10-24 11:52:46 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-10-24 11:52:46 -0500 |
commit | da548d20f482c09241a9dad08dd4c76dbb89ec8d (patch) | |
tree | 27204eb5b295341f9e8deb92a03782cb423664dd | |
parent | 6086694d40f8df09db79bc9a7b7eec29131f424a (diff) |
Avoid suppressing panic messages (#2323)
* print `PanicInfo` using hook
* update changelog
-rw-r--r-- | CHANGELOG.md | 1 | ||||
-rw-r--r-- | bindgen-cli/main.rs | 3 |
2 files changed, 3 insertions, 1 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index 87a74acd..de08d829 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -153,6 +153,7 @@ * Regex inputs are sanitized so alternation (`a|b`) is handled correctly but wildcard patterns (`*`) are now considered invalid. + * the `ParseCallbacks`trait does not require to implement `UnwindSafe`. ## Removed diff --git a/bindgen-cli/main.rs b/bindgen-cli/main.rs index fed454af..a3b36126 100644 --- a/bindgen-cli/main.rs +++ b/bindgen-cli/main.rs @@ -41,10 +41,11 @@ pub fn main() { #[cfg(feature = "logging")] clang_version_check(); - std::panic::set_hook(Box::new(move |_info| { + std::panic::set_hook(Box::new(move |info| { if verbose { print_verbose_err() } + println!("{}", info); })); let bindings = |