diff options
| author | Alexandros Naskos <alex_naskos@hotmail.com> | 2020-06-24 19:01:38 +0300 |
|---|---|---|
| committer | Alexandros Naskos <alex_naskos@hotmail.com> | 2020-06-24 19:01:38 +0300 |
| commit | ff2ddcf38d7a2f0fbed40f645278a09ca940a68a (patch) | |
| tree | 557d0984b23f2b59b1165b53d299f1468b5d742f /doc | |
| parent | 7f342451b6f2339da15fec199814365391500c11 (diff) | |
| download | zig-ff2ddcf38d7a2f0fbed40f645278a09ca940a68a.tar.gz zig-ff2ddcf38d7a2f0fbed40f645278a09ca940a68a.zip | |
Updated @asyncCall docs
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 8974e6d175..95b7171c44 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -6689,7 +6689,7 @@ comptime { {#header_close#} {#header_open|@asyncCall#} - <pre>{#syntax#}@asyncCall(frame_buffer: []align(@alignOf(@Frame(anyAsyncFunction))) u8, result_ptr, function_ptr, args: ...) anyframe->T{#endsyntax#}</pre> + <pre>{#syntax#}@asyncCall(frame_buffer: []align(@alignOf(@Frame(anyAsyncFunction))) u8, result_ptr, function_ptr, args: var) anyframe->T{#endsyntax#}</pre> <p> {#syntax#}@asyncCall{#endsyntax#} performs an {#syntax#}async{#endsyntax#} call on a function pointer, which may or may not be an {#link|async function|Async Functions#}. @@ -6716,7 +6716,7 @@ test "async fn pointer in a struct field" { }; var foo = Foo{ .bar = func }; var bytes: [64]u8 align(@alignOf(@Frame(func))) = undefined; - const f = @asyncCall(&bytes, {}, foo.bar, &data); + const f = @asyncCall(&bytes, {}, foo.bar, .{&data}); assert(data == 2); resume f; assert(data == 4); |
