Rename expectation files to contain only one dot.
This is needed for the Cython tests as of Cython 3.
The following script was used in a clean repository
to rename the files:
```sh
ls | sed -E -n 's/(.*)\.(both|tag)?((\..*)?\.(c|cpp|pyx))/mv "\1.\2\3" "\1_\2\3"/p' | sh
```
Cython 3.0 deprecated `IF` and `DEF`. Until this is fixed
allow warnings in our `Cython` tests.
Background: https://github.com/cython/cython/issues/4310
Note the warnings will become hard errors in the future.
When specifying `cbindgen` as a dependency via git, several 'skipping duplicate
package' warnings pop up regarding some of the test crates.
The warning seems to be spurious given that the test packages aren't needed when
depending on `cbindgen` (see https://github.com/rust-lang/cargo/issues/10752),
but while a fix is being considered for Cargo, this commit disambiguates the
duplicated package names by referring to their relative paths.
Add an option to output a depfile for outside build-systems to learn
the source file dependencies of the bindings.
This can be used by 3rd party build system integrations to only rerun
bindgen when necessary.
Testing is done via CMake integration tests, since CMake
is a 3rd party buildsystem which supports depfiles.
Since our MSRV is now Rust 1.54, we can rely on cargo setting `CARGO_BIN_EXE_cbindgen`
to the cbindgen path in integration tests.
This is more reliable than guessing the path, since cargo knows where it placed the bin.
The common `tag` should already be enough, al other tags are identical to it.
In Cython case they only create noise because the declarations only introduce names and do not determine layouts.
As seen in hashbrown:
#[cfg(feature = "raw")]
/// Experimental and unsafe `RawTable` API. This module is only available if the
/// `raw` feature is enabled.
pub mod raw {
// The RawTable API is still experimental and is not properly documented yet.
#[allow(missing_docs)]
#[path = "mod.rs"]
mod inner;
pub use inner::*;
#[cfg(feature = "rayon")]
pub mod rayon {
pub use crate::external_trait_impls::rayon::raw::*;
}
}
This was an oversight in 1903686f9eb09f587885d579f3e14c990e799938
because the code I grabbed to visit the generics was dealing with them
somewhere else.