Skip to content
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

Expose Almanac to C++ #388

Open
ChristopherRabotin opened this issue Mar 6, 2025 · 0 comments
Open

Expose Almanac to C++ #388

ChristopherRabotin opened this issue Mar 6, 2025 · 0 comments
Labels

Comments

@ChristopherRabotin
Copy link
Member

High level description

As a stakeholder, I need the Almanac structure to be exposed to C++ so that file loading can be performed from C++ code.

Requirements

Expose the Almanac structure and the associated load function to C++ using the cxx Rust crate. The Rust load function takes a string and returns a copy of the Almanac using move semantics. It is critical to ensure that the move semantics do not lead to memory leaks when used from C++.

Test plans

  • Implement C++ bindings for the Almanac structure.
  • Expose the load function so that it is accessible in C++.
  • Ensure that the Rust-side move semantics are preserved and do not cause memory leaks.
  • Write C++ tests that verify the expected behavior and absence of memory leaks.
  • Update the documentation with C++ usage examples and any caveats regarding memory management.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant