checker: fix typo explictly -> explicitly in error message (#21698)

This commit is contained in:
Ikko Eltociear Ashimine 2024-06-19 16:21:46 +09:00 committed by GitHub
parent 78b77b9f14
commit d7cc5c8877
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
3 changed files with 3 additions and 3 deletions

View File

@ -3913,7 +3913,7 @@ fn (mut c Checker) ident(mut node ast.Ident) ast.Type {
c.error('undefined variable `${node.name}`', node.pos)
} else {
c.add_error_detail('use `fn [${node.name}] () {` instead of `fn () {`')
c.error('`${node.name}` must be explictly listed as inherited variable to be used inside a closure',
c.error('`${node.name}` must be explicitly listed as inherited variable to be used inside a closure',
node.pos)
}
return ast.void_type

View File

@ -5,7 +5,7 @@ vlib/v/checker/tests/anon_fn_arg_type_err.vv:6:14: error: use `_` to name an unu
| ^
7 | return i
8 | }
vlib/v/checker/tests/anon_fn_arg_type_err.vv:7:10: error: `i` must be explictly listed as inherited variable to be used inside a closure
vlib/v/checker/tests/anon_fn_arg_type_err.vv:7:10: error: `i` must be explicitly listed as inherited variable to be used inside a closure
5 |
6 | func := fn (i) int {
7 | return i

View File

@ -1,4 +1,4 @@
vlib/v/parser/tests/closure_not_declared.vv:4:9: error: `a` must be explictly listed as inherited variable to be used inside a closure
vlib/v/parser/tests/closure_not_declared.vv:4:9: error: `a` must be explicitly listed as inherited variable to be used inside a closure
2 | a := 1
3 | f := fn () {
4 | print(a)