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

Recognize C array of relocatable element type in struct as relocatable #1021

Merged
merged 2 commits into from Mar 8, 2022

Conversation

dtolnay
Copy link
Owner

@dtolnay dtolnay commented Mar 8, 2022

The code added to the test suite here previously failed with:

cxx-test-suite-5d36df47f94f2b63/out/cxxbridge/sources/tests/ffi/lib.rs.cc:1387:45: error: static assertion failed: type tests::Buffer should be trivially move constructible and trivially destructible in C++ to be used as a field of `Array` in Rust
 1387 |     ::rust::IsRelocatable<::tests::Buffer>::value,
      |     ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~

@dtolnay dtolnay merged commit a6e1cd1 into master Mar 8, 2022
@dtolnay dtolnay deleted the carray branch March 8, 2022 20:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant