From c647314bffb572013ab57afe1e5f8cecba6411dc Mon Sep 17 00:00:00 2001 From: Yisu Remy Wang Date: Sat, 8 Feb 2025 00:16:28 -0800 Subject: [PATCH] Reference a many-item pointer into a single-item one --- .../version-0.13/01-language-basics/13-many-item-pointers.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/website/versioned_docs/version-0.13/01-language-basics/13-many-item-pointers.mdx b/website/versioned_docs/version-0.13/01-language-basics/13-many-item-pointers.mdx index d6dbb0f..75d5f80 100644 --- a/website/versioned_docs/version-0.13/01-language-basics/13-many-item-pointers.mdx +++ b/website/versioned_docs/version-0.13/01-language-basics/13-many-item-pointers.mdx @@ -33,5 +33,5 @@ the length of these buffers. It's worth noting that this function is effectively trusting us to pass us a valid length for the given buffer. We can convert from a many-item pointer to a single-item pointer by either -indexing an element and dereferencing that, or by using `@ptrCast` to cast the +indexing an element and referencing that, or by using `@ptrCast` to cast the pointer type. This is only valid when the buffer has a length of at least 1.