aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorTechatrix <19954306+Techatrix@users.noreply.github.com>2022-09-28 12:30:55 +0200
committerGitHub <noreply@github.com>2022-09-28 13:30:55 +0300
commit9a2f17f9f9dfde9c5438ccb439b727e1e814c4f5 (patch)
treef3c7d2183c2eaf8d18aaf9b074680d5c0de88964 /doc
parent779c2daa196c0cc8ac6d59441eb47228c1d65aa5 (diff)
downloadzig-9a2f17f9f9dfde9c5438ccb439b727e1e814c4f5.tar.gz
zig-9a2f17f9f9dfde9c5438ccb439b727e1e814c4f5.zip
Docs: clarify unreachable for ReleaseSmall
Diffstat (limited to 'doc')
-rw-r--r--doc/langref.html.in7
1 files changed, 3 insertions, 4 deletions
diff --git a/doc/langref.html.in b/doc/langref.html.in
index 418302bd83..ef9e8402c1 100644
--- a/doc/langref.html.in
+++ b/doc/langref.html.in
@@ -4903,13 +4903,12 @@ test "errdefer unwinding" {
{#header_close#}
{#header_open|unreachable#}
<p>
- In {#syntax#}Debug{#endsyntax#} and {#syntax#}ReleaseSafe{#endsyntax#} mode, and when using <kbd>zig test</kbd>,
+ In {#link|Debug#} and {#link|ReleaseSafe#} mode
{#syntax#}unreachable{#endsyntax#} emits a call to {#syntax#}panic{#endsyntax#} with the message <code>reached unreachable code</code>.
</p>
<p>
- In {#syntax#}ReleaseFast{#endsyntax#} mode, the optimizer uses the assumption that {#syntax#}unreachable{#endsyntax#} code
- will never be hit to perform optimizations. However, <kbd>zig test</kbd> even in {#syntax#}ReleaseFast{#endsyntax#} mode
- still emits {#syntax#}unreachable{#endsyntax#} as calls to {#syntax#}panic{#endsyntax#}.
+ In {#link|ReleaseFast#} and {#link|ReleaseSmall#} mode, the optimizer uses the assumption that {#syntax#}unreachable{#endsyntax#} code
+ will never be hit to perform optimizations.
</p>
{#header_open|Basics#}
{#code_begin|test|test_unreachable#}