aboutsummaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
authorMichael Byrne <michael@michaelbyrne.io>2021-10-23 15:13:35 +1100
committerAndrew Kelley <andrew@ziglang.org>2021-10-23 02:57:20 -0400
commitee98d8700818aa667137e3aa580b16df2ba6d680 (patch)
treee3498482f1fe65d46718031d93132cda309d1fad /doc
parent6aeb6bcc84f48fdc88374fa4a3d5a2b9d0bd147e (diff)
downloadzig-ee98d8700818aa667137e3aa580b16df2ba6d680.tar.gz
zig-ee98d8700818aa667137e3aa580b16df2ba6d680.zip
Minor rewording of "Shadowing" section within language reference
Diffstat (limited to 'doc')
-rw-r--r--doc/langref.html.in7
1 files changed, 4 insertions, 3 deletions
diff --git a/doc/langref.html.in b/doc/langref.html.in
index 4fbc4ef302..9e5edee9f8 100644
--- a/doc/langref.html.in
+++ b/doc/langref.html.in
@@ -3872,7 +3872,7 @@ test "labeled break from labeled block expression" {
{#see_also|Labeled while|Labeled for#}
{#header_open|Shadowing#}
- <p>It is never allowed for an identifier to "hide" another one by using the same name:</p>
+ <p>Identifiers are never allowed to "hide" other identifiers by using the same name:</p>
{#code_begin|test_err|local shadows declaration#}
const pi = 3.14;
@@ -3884,8 +3884,9 @@ test "inside test block" {
}
{#code_end#}
<p>
- Because of this, when you read Zig code you can rely on an identifier always meaning the same thing,
- within the scope it is defined. Note that you can, however use the same name if the scopes are separate:
+ Because of this, when you read Zig code you can always rely on an identifier to consistently mean
+ the same thing within the scope it is defined. Note that you can, however, use the same name if
+ the scopes are separate:
</p>
{#code_begin|test|test_scopes#}
test "separate scopes" {