@@ -321,7 +321,7 @@ func (f *file) IndexSymbols(ctx context.Context) {
321321 for _ , sym := range unresolved {
322322 switch kind := sym .kind .(type ) {
323323 case * reference :
324- def := f .resolveASTDefinition (ctx , kind .def , kind .fullName )
324+ def := f .resolveASTDefinition (kind .def , kind .fullName )
325325 sym .def = def
326326 if def == nil {
327327 // In the case where the symbol is not resolved, we continue
@@ -339,7 +339,7 @@ func (f *file) IndexSymbols(ctx context.Context) {
339339 }
340340 referenceable .references = append (referenceable .references , sym )
341341 case * option :
342- def := f .resolveASTDefinition (ctx , kind .def , kind .defFullName )
342+ def := f .resolveASTDefinition (kind .def , kind .defFullName )
343343 sym .def = def
344344 if def != nil {
345345 referenceable , ok := def .kind .(* referenceable )
@@ -354,7 +354,7 @@ func (f *file) IndexSymbols(ctx context.Context) {
354354 referenceable .references = append (referenceable .references , sym )
355355 }
356356 }
357- typeDef := f .resolveASTDefinition (ctx , kind .typeDef , kind .typeDefFullName )
357+ typeDef := f .resolveASTDefinition (kind .typeDef , kind .typeDefFullName )
358358 sym .typeDef = typeDef
359359 default :
360360 // This shouldn't happen, logging a warning
@@ -756,9 +756,9 @@ func (f *file) messageToSymbolsHelper(msg ir.MessageValue, index int, parents []
756756
757757// resolveASTDefinition is a helper for resolving the [ast.DeclDef] to the *[symbol], if
758758// there is a matching indexed *[symbol].
759- func (f * file ) resolveASTDefinition (ctx context. Context , def ast.DeclDef , defName ir.FullName ) * symbol {
759+ func (f * file ) resolveASTDefinition (def ast.DeclDef , defName ir.FullName ) * symbol {
760760 // First check if the definition is in the current file.
761- if def .Span ().Path () == f .objectInfo . LocalPath () {
761+ if def .Span ().Path () == f .file . Path () {
762762 return f .referenceableSymbols [defName ]
763763 }
764764 // No workspace, we cannot resolve the AST definition from outside of the file.
0 commit comments