diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2019-11-07 19:05:52 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-11-08 15:57:25 -0500 |
| commit | aef04aff0c60a82ab5c2336ca999a918b1905c68 (patch) | |
| tree | edc0d0687b495a51be83bec09e11cd6a575d8ad0 | |
| parent | aa0daea5415dd2a20e4d7c2fd047b7bcee6c9ea4 (diff) | |
| download | zig-aef04aff0c60a82ab5c2336ca999a918b1905c68.tar.gz zig-aef04aff0c60a82ab5c2336ca999a918b1905c68.zip | |
initial docs for `@as`
| -rw-r--r-- | doc/langref.html.in | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/doc/langref.html.in b/doc/langref.html.in index 3eb30c3058..a4000f1b47 100644 --- a/doc/langref.html.in +++ b/doc/langref.html.in @@ -6445,6 +6445,14 @@ comptime { </p> {#header_close#} + {#header_open|@as#} + <pre>{#syntax#}@as(comptime T: type, expression) T{#endsyntax#}</pre> + <p> + Performs {#link|Type Coercion#}. This cast is allowed when the conversion is unambiguous and safe, + and is the preferred way to convert between types, whenever possible. + </p> + {#header_close#} + {#header_open|@asyncCall#} <pre>{#syntax#}@asyncCall(frame_buffer: []align(@alignOf(@Frame(anyAsyncFunction))) u8, result_ptr, function_ptr, args: ...) anyframe->T{#endsyntax#}</pre> <p> |
