-
Notifications
You must be signed in to change notification settings - Fork 706
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
thread 'main' panicked at .... is not a valid Ident #2700
Comments
You need to update bindgen. You're using 0.56.0 which doesn't contain the relevant fix iirc. |
Am on 0.56.0.
|
What can I do to debug this? It panics before the bindings are output. Is there a debug mode I can turn on? |
You need a newer version of bindgen. We fixed this a while ago. #2319 landed in 0.65.1 and such. |
Sorry misread your comment that you needed to be running 0.56.0 with the fix. Thanks. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
The problem occurs on an otherwise working codebase when built on Sonoma 14.0. Looking at the very few times I can find this message coming up, it was related to the wrong libclang being used, but I don't have another other copies or clang or llvm.
How should I go about debugging this?
Input C/C++ Header
Failure is somewhere in MacOS system headers on Sonoma 14.0.
Bindgen Invocation
Actual Results
thread 'main' panicked at '"wait_struct_(unnamed_at_/Applications/Xcode_app/Contents/Developer/Platforms/MacOSX_platform/Developer/SDKs/MacOSX_sdk/usr/include/sys/wait_h_199_2)" is not a valid Ident', /Users/aholtzma/.cargo/registry/src/index.crates.io-6f17d22bba15001f/bindgen-0.56.0/src/ir/context.rs:846:9
stack backtrace:
0: rust_begin_unwind
at /rustc/5680fa18feaa87f3ff04063800aec256c3d4b4be/library/std/src/panicking.rs:593:5
1: core::panicking::panic_fmt
at /rustc/5680fa18feaa87f3ff04063800aec256c3d4b4be/library/core/src/panicking.rs:67:14
2: proc_macro2::fallback::validate_ident
3: proc_macro2::fallback::Ident::new_checked
4: proc_macro2::imp::Ident::new_checked
5: proc_macro2::Ident::new
6: bindgen::ir::context::BindgenContext::rust_ident_raw
7: bindgen::ir::context::BindgenContext::rust_ident
8: <bindgen::ir::comp::CompInfo as bindgen::codegen::CodeGenerator>::codegen
9: <bindgen::ir::ty::Type as bindgen::codegen::CodeGenerator>::codegen
10: <bindgen::ir::item::Item as bindgen::codegen::CodeGenerator>::codegen
11: <bindgen::ir::comp::CompInfo as bindgen::codegen::CodeGenerator>::codegen
12: <bindgen::ir::ty::Type as bindgen::codegen::CodeGenerator>::codegen
13: <bindgen::ir::item::Item as bindgen::codegen::CodeGenerator>::codegen
14: <bindgen::ir::module::Module as bindgen::codegen::CodeGenerator>::codegen::{{closure}}
15: <bindgen::ir::module::Module as bindgen::codegen::CodeGenerator>::codegen
16: <bindgen::ir::item::Item as bindgen::codegen::CodeGenerator>::codegen
17: bindgen::codegen::codegen::{{closure}}
18: bindgen::ir::context::BindgenContext::gen
19: bindgen::codegen::codegen
20: bindgen::Bindings::generate
21: bindgen::Builder::generate
22: build_script_build::main
23: core::ops::function::FnOnce::call_once
note: Some details are omitted, run with
RUST_BACKTRACE=full
for a verbose backtrace.Expected Results
The build to be successful.
The text was updated successfully, but these errors were encountered: