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

Convert to arbitrary_self_types_pointers. #1390

Merged
merged 2 commits into from
Sep 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ exclude = [ ".github", "book", "tools" ]
resolver = "2"

[features]
arbitrary_self_types = []
arbitrary_self_types_pointers = []

[dependencies]
autocxx-macro = { path="macro", version="0.27.0" }
Expand Down
2 changes: 1 addition & 1 deletion examples/reference-wrappers/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

// Necessary to be able to call methods on reference wrappers.
// For that reason, this example only builds on nightly Rust.
#![feature(arbitrary_self_types)]
#![feature(arbitrary_self_types_pointers)]

use autocxx::prelude::*;
use std::pin::Pin;
Expand Down
4 changes: 2 additions & 2 deletions integration-tests/tests/cpprefs_test.rs
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ fn run_cpprefs_test(
generate_pods: &[&str],
) {
if !arbitrary_self_types_supported() {
// "unsafe_references_wrapped" requires arbitrary_self_types, which requires nightly.
// "unsafe_references_wrapped" requires arbitrary_self_types_pointers, which requires nightly.
return;
}
do_run_test(
Expand All @@ -39,7 +39,7 @@ fn run_cpprefs_test(
None,
"unsafe_references_wrapped",
Some(quote! {
#![feature(arbitrary_self_types)]
#![feature(arbitrary_self_types_pointers)]
}),
)
.unwrap()
Expand Down
2 changes: 1 addition & 1 deletion src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -270,7 +270,7 @@ macro_rules! concrete {
/// them to be wrapped in a `CppRef` type: see [`CppRef`].
/// This only works on nightly Rust because it
/// depends upon an unstable feature
/// (`arbitrary_self_types`). However, it should
/// (`arbitrary_self_types_pointers`). However, it should
/// eliminate all undefined behavior related to Rust's
/// stricter aliasing rules than C++.
#[macro_export]
Expand Down
4 changes: 2 additions & 2 deletions src/reference_wrapper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ use cxx::{memory::UniquePtrTarget, UniquePtr};
/// As noted, one of the main reasons for this type is to call methods.
/// Unfortunately, that depends on unstable Rust features. If you can't
/// call methods on one of these references, check you're using nightly
/// and add `#![feature(arbitrary_self_types)]` to your crate.
/// and add `#![feature(arbitrary_self_types_pointers)]` to your crate.
///
/// # Lifetimes and cloneability
///
Expand Down Expand Up @@ -566,7 +566,7 @@ impl<T: ?Sized> AsCppMutRef<T> for PhantomReferentMut<T> {
}
}

#[cfg(all(feature = "arbitrary_self_types", test))]
#[cfg(all(feature = "arbitrary_self_types_pointers", test))]
mod tests {
use super::*;

Expand Down
Loading