diff options
| author | Marc Tiehuis <marctiehuis@gmail.com> | 2018-08-18 12:06:25 +1200 |
|---|---|---|
| committer | Marc Tiehuis <marctiehuis@gmail.com> | 2018-08-18 12:06:25 +1200 |
| commit | 1da93caced5511d5b2d666fe40c5db108580e2aa (patch) | |
| tree | cd8e64d8013af47166e6369bf1b241013ff43837 /doc | |
| parent | 4c95b2f9d1c6fd020c484fef53f796448203fb12 (diff) | |
| download | zig-1da93caced5511d5b2d666fe40c5db108580e2aa.tar.gz zig-1da93caced5511d5b2d666fe40c5db108580e2aa.zip | |
docs: correct @memcpy, @memset function signatures
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/langref.html.in | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/doc/langref.html.in b/doc/langref.html.in index 761cd72125..d8da0de1c8 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -5528,7 +5528,7 @@ fn add(a: i32, b: i32) i32 { return a + b; } <p>Returns the field type of a struct or union.</p> {#header_close#} {#header_open|@memcpy#} - <pre><code class="zig">@memcpy(noalias dest: *u8, noalias source: *const u8, byte_count: usize)</code></pre> + <pre><code class="zig">@memcpy(noalias dest: [*]u8, noalias source: [*]const u8, byte_count: usize)</code></pre> <p> This function copies bytes from one region of memory to another. <code>dest</code> and <code>source</code> are both pointers and must not overlap. @@ -5546,7 +5546,7 @@ fn add(a: i32, b: i32) i32 { return a + b; } mem.copy(u8, dest[0...byte_count], source[0...byte_count]);</code></pre> {#header_close#} {#header_open|@memset#} - <pre><code class="zig">@memset(dest: *u8, c: u8, byte_count: usize)</code></pre> + <pre><code class="zig">@memset(dest: [*]u8, c: u8, byte_count: usize)</code></pre> <p> This function sets a region of memory to <code>c</code>. <code>dest</code> is a pointer. </p> |
