Skip to content

Commit 8ff4a9f

Browse files
authored
Merge pull request #34 from frengor/dev
* Update to 0.6.2 * Use thiserror 2.0 instead of thiserror-core * Small update to the Trace documentation * (nightly only) Update `derive(SmartPointer)` with `derive(CoercePointee)`
2 parents e6f2f89 + f1abc08 commit 8ff4a9f

File tree

4 files changed

+7
-7
lines changed

4 files changed

+7
-7
lines changed

Cargo.toml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ edition.workspace = true
1414
members = ["derive"]
1515

1616
[workspace.package]
17-
version = "0.6.1" # Also update in [dependencies.rust-cc-derive.version]
17+
version = "0.6.2" # Also update in [dependencies.rust-cc-derive.version]
1818
authors = ["fren_gor <[email protected]>"]
1919
repository = "https://github.com/frengor/rust-cc"
2020
categories = ["memory-management", "no-std"]
@@ -49,9 +49,9 @@ std = ["slotmap?/std", "thiserror/std"]
4949
pedantic-debug-assertions = []
5050

5151
[dependencies]
52-
rust-cc-derive = { path = "./derive", version = "=0.6.1", optional = true }
52+
rust-cc-derive = { path = "./derive", version = "=0.6.2", optional = true }
5353
slotmap = { version = "1.0", optional = true }
54-
thiserror = { version = "1.0", package = "thiserror-core", default-features = false }
54+
thiserror = { version = "2.0", default-features = false }
5555

5656
[dev-dependencies]
5757
iai-callgrind = "=0.12.2"

src/cc.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ use core::hash::{Hash, Hasher};
1313
use core::panic::{RefUnwindSafe, UnwindSafe};
1414
#[cfg(feature = "nightly")]
1515
use core::{
16-
marker::SmartPointer,
16+
marker::CoercePointee,
1717
ptr::{metadata, DynMetadata},
1818
};
1919

@@ -28,7 +28,7 @@ use crate::weak::weak_counter_marker::WeakCounterMarker;
2828
/// A thread-local cycle collected pointer.
2929
///
3030
/// See the [module-level documentation][`mod@crate`] for more details.
31-
#[cfg_attr(feature = "nightly", derive(SmartPointer))]
31+
#[cfg_attr(feature = "nightly", derive(CoercePointee))]
3232
#[repr(transparent)]
3333
pub struct Cc<#[cfg_attr(feature = "nightly", pointee)] T: ?Sized + Trace + 'static> {
3434
inner: NonNull<CcBox<T>>,

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ cleanable.clean();
131131
//! [`Sync`]: `std::marker::Sync`
132132
//! [`Rc`]: `std::rc::Rc`
133133
134-
#![cfg_attr(feature = "nightly", feature(unsize, coerce_unsized, ptr_metadata, derive_smart_pointer))]
134+
#![cfg_attr(feature = "nightly", feature(unsize, coerce_unsized, ptr_metadata, derive_coerce_pointee))]
135135
#![cfg_attr(all(feature = "nightly", not(feature = "std")), feature(thread_local))] // no-std related unstable features
136136
#![cfg_attr(doc_auto_cfg, feature(doc_auto_cfg))]
137137
#![cfg_attr(not(feature = "std"), no_std)]

src/trace.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ struct Foo<A: Trace + 'static, B: Trace + 'static> {
9898
/// must be a subset of the [`Cc`] instances traced in the first one.
9999
/// Tracing can be detected using the [`state::is_tracing`] function. If it never returned `false` between two [`trace`] calls
100100
/// on the same value, then they are part of the same tracing phase.
101-
/// * The [`trace`] implementation must not create, clone, dereference or drop any [`Cc`].
101+
/// * The [`trace`] implementation must not create, clone, move, dereference or drop any [`Cc`].
102102
/// * If the implementing type implements [`Drop`], then the [`Drop::drop`] implementation must not create, clone, move, dereference, drop or call
103103
/// any method on any [`Cc`] instance.
104104
///

0 commit comments

Comments
 (0)