mirror of
https://gitee.com/openharmony/third_party_rust_cxx
synced 2024-11-24 07:40:19 +00:00
7907966838
To preserve parity with item-level #[namespace = "..."] which is currently restricted by rustc to a quoted string.
14 lines
306 B
Rust
14 lines
306 B
Rust
// Rustfmt mangles the extern type alias.
|
|
// https://github.com/rust-lang/rustfmt/issues/4159
|
|
#[rustfmt::skip]
|
|
#[cxx::bridge(namespace = "tests")]
|
|
pub mod ffi {
|
|
extern "C" {
|
|
include!("tests/ffi/tests.h");
|
|
|
|
type C = crate::ffi::C;
|
|
|
|
fn c_take_unique_ptr(c: UniquePtr<C>);
|
|
}
|
|
}
|