Skip to content

Commit f624ef4

Browse files
committed
ByteAddressableBuffer: fixup docs
1 parent 7f532f5 commit f624ef4

File tree

1 file changed

+4
-6
lines changed

1 file changed

+4
-6
lines changed

crates/spirv-std/src/byte_addressable_buffer.rs

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -44,9 +44,7 @@ unsafe fn buffer_store_intrinsic<T>(
4444
}
4545

4646
/// `ByteAddressableBuffer` is a view to an untyped blob of data, allowing
47-
/// loads and stores of arbitrary basic data types at arbitrary indices. Use
48-
/// `from_slice()` or `from_mut_slice()` to create the `ByteAddressableBuffer`,
49-
/// with only the mutable slice allowing stores.
47+
/// loads and stores of arbitrary basic data types at arbitrary indices.
5048
///
5149
/// # Alignment
5250
/// All data must be aligned to size 4, each element within the data (e.g.
@@ -58,9 +56,9 @@ unsafe fn buffer_store_intrinsic<T>(
5856
///
5957
/// # Safety
6058
/// Using these functions allows reading a different type from the buffer than
61-
/// was originally written (by [`MutByteAddressableBuffer`] or the host API),
62-
/// allowing all sorts of safety guarantees to be bypassed (effectively a
63-
/// transmute).
59+
/// was originally written (by a previous `store()` or the host API), allowing
60+
/// all sorts of safety guarantees to be bypassed, making it effectively a
61+
/// transmute.
6462
#[repr(transparent)]
6563
pub struct ByteAddressableBuffer<T> {
6664
/// The underlying array of bytes, able to be directly accessed.

0 commit comments

Comments
 (0)