rust-cpp
rust-cpp copied to clipboard
Embed C++ directly inside your rust code!
I have tried this crate using the following examples: https://docs.rs/cpp/0.5.5/cpp/ https://docs.rs/cpp/0.5.5/cpp/macro.cpp.html However, my linker is failing and prints the following error: ```undefined reference to `__cpp_closure_17383989895670653357'``` What am I doing wrong?...
In the current state, this crate works with Rust 2015 only under a specific conditions: explicit `extern crate core;` must be added to the top of the project's main file...
Hello! I'm trying to use a Rust static variable as a C++ non-type template parameter. Is this possible? This is a simple example which outlines what I'm trying to do:...
Declarative macros like the one below could use the relatively new visibility aka `:vis` macro meta-variable instead of manual `pub($tt*)` etc. It had some [issues](https://github.com/rust-lang/rust/issues/71422) in past, but now it's...
C++ allows the use of self-referential structures by convention; Rust does not. Using cpp_class! to wrap a class that is not trivially relocatable is unsafe because Rust might move the...
In theory this would just be a case of `Walker` detecting include macro calls in its `Folder` implementation. Initially it could be limited to handling includes of the form ```rust...
I'll look into working on this tomorrow, but its a bit annoying that the whole crate is rebuilt when I run `cargo run`, having not changed anything.
I'm noticing that 99% of my errors are type errors during calling `cpp!` macro: // Handle struct Wrap { ptr: ::libc::c_void } pub fn test(wrap: &mut Wrap) { cpp!([wrap as...
I'm evaluating different options to use C++ code from rust, and an important point for me is that error handling should be seamless. It would be convenient if what happens...
Using this crate with `qmetaobject` on MacOS arm64, I get this strange error: ``` = note: ld: warning: ignoring file /Users/lysan/edit/target/debug/build/edit-ed5f1e2f905ca358/out/librust_cpp_generated.a, building for macOS-arm64 but attempting to link with file...