-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Related Error SpansSpecifying regions for error messages/diagnostics on multiple locations.Specifying regions for error messages/diagnostics on multiple locations.FixedA PR has been merged for this issueA PR has been merged for this issue
Milestone
Description
Now that we support multiple related spans for errors (#10489, #22789, #24548), we'd like to improve an existing error message.
Currently, we provide certain errors for using certain declarations before they're actually declared:
Block-scoped variable '{0}' used before its declaration.
Class '{0}' used before its declaration.
Enum '{0}' used before its declaration.
We can actually provide the definition location as a related span for some extra context.
'{0}' was accessed prior to being declared here.
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Related Error SpansSpecifying regions for error messages/diagnostics on multiple locations.Specifying regions for error messages/diagnostics on multiple locations.FixedA PR has been merged for this issueA PR has been merged for this issue