authorgravatar for hello@nektro.netMeghan Denny <hello@nektro.net> 2021-08-01 02:42:05-07:00
committergravatar for noreply@github.comGitHub <noreply@github.com> 2021-08-01 12:42:05+03:00
log32069d23301f624a7cdd4f1763c2de24f7a234ab
tree097db48913b0a397563aed67479a0d7afb93fb67
parent5589edf45ce20b5b6d893b1a5488007981322550
signaturebadge-question-mark Signed by PGP key 4AEE18F83AFDEB23

langref- fix use after block error code


1 files changed, 2 insertions(+), 1 deletions(-)

doc/langref.html.in+2-1
...@@ -3422,10 +3422,11 @@ test "call foo" {...@@ -3422,10 +3422,11 @@ test "call foo" {
3422 <p>3422 <p>
3423 Blocks are used to limit the scope of variable declarations:3423 Blocks are used to limit the scope of variable declarations:
3424 </p>3424 </p>
3425 {#code_begin|test_err|unused local variable#}3425 {#code_begin|test_err|use of undeclared identifier 'x'#}
3426test "access variable after block scope" {3426test "access variable after block scope" {
3427 {3427 {
3428 var x: i32 = 1;3428 var x: i32 = 1;
3429 _ = x;
3429 }3430 }
3430 x += 1;3431 x += 1;
3431}3432}