Files
codegraph/__tests__
Colby Mchenry 0c22acf36c fix(ts): a call on a known class goes through that class's own bases (#2656)
A TS/JS call on a field or a typed local whose class the file's import
names went, when that class didn't declare the method itself, to any
class with the method and a matching name: vscode's
`this._storage.dispose` (`Storage extends Disposable`) reached a test
fixture's `Disposable`, Copilot's `Emitter extends lsp.Emitter`, whose
`fire` is the package's, reached a test fixture's `Emitter::fire`, and
`this.logService.trace()` on `ILogService extends ILogger` linked nowhere.
Now that class decides: its own method, or the nearest one up its head's
`extends` / `implements`, each supertype found the way its subtype's file
names it. For a field, a chain that is fully known and has no such
method, or leaves the project for a package, links nothing. A typed
local, whose type an unscoped scan reads, takes only a method found. A
supertype that can't be found, or a same-named function-typed property,
leaves the call to the lookups that follow.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-19 09:46:26 +00:00
..