microsoft / microsoft/TypeScript
Go to definition on callable property returns two definitions
Open
Nobody has claimed this yet.
Needs Proposal
Suggestion
- Dominant language
- Go
- Stars
- 111k
- Forks
- 14.3k
- Avg merge
- 2d 4h
- Merged PRs (30d)
- 132
Description
Bug Report
🔎 Search Terms
- go to definition
- callable
🕗 Version & Regression Information
4.3.0-dev.20210316
⏯ Playground Link
Playground link with relevant code
💻 Code
interface ICallable {
(): any
}
class K {
callable: ICallable;
}
new K().callable()
Run go to definition on callable
🙁 Actual behavior
Two definitions are returned, for for K.callable and one for (): any in ICallable
🙂 Expected behavior
Just the definition for K.callable is returned
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the linked TypeScript Playground and reproduce go to definition on callable in the provided interface and class example. Trace the language-service definition lookup for the call expression; done means the result contains only K.callable, not the (): any signature in ICallable.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- developer-experience, devtools
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100