checker: remove pos+1 on innermost call
parent
0d7cc8829a
commit
c599a4c7de
|
@ -2551,7 +2551,7 @@ pub fn (mut c Checker) ident(mut ident ast.Ident) table.Type {
|
||||||
return info.typ
|
return info.typ
|
||||||
} else if ident.kind == .unresolved {
|
} else if ident.kind == .unresolved {
|
||||||
// first use
|
// first use
|
||||||
start_scope := c.file.scope.innermost(ident.pos.pos + 1)
|
start_scope := c.file.scope.innermost(ident.pos.pos)
|
||||||
if obj1 := start_scope.find(ident.name) {
|
if obj1 := start_scope.find(ident.name) {
|
||||||
match mut obj1 as obj {
|
match mut obj1 as obj {
|
||||||
ast.GlobalDecl {
|
ast.GlobalDecl {
|
||||||
|
|
Loading…
Reference in New Issue