Skip to content

Commit 8effca5

Browse files
authored
Add deprecated LayoutVerified type alias (#222)
This should help make the transition to 0.7.0 easier, as code which currently uses `LayoutVerified` will get a deprecation warning instead of a (much less helpful) "not found" error. Closes #221
1 parent ab7ed8f commit 8effca5

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

src/lib.rs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1571,6 +1571,11 @@ macro_rules! transmute {
15711571
/// ```
15721572
pub struct Ref<B, T: ?Sized>(B, PhantomData<T>);
15731573

1574+
/// Deprecated: prefer [`Ref`] instead.
1575+
#[deprecated(since = "0.7.0", note = "LayoutVerified has been renamed to Ref")]
1576+
#[doc(hidden)]
1577+
pub type LayoutVerified<B, T> = Ref<B, T>;
1578+
15741579
impl<B, T> Ref<B, T>
15751580
where
15761581
B: ByteSlice,

0 commit comments

Comments
 (0)