-
Notifications
You must be signed in to change notification settings - Fork 13.2k
Closed
Labels
FixedA PR has been merged for this issueA PR has been merged for this issueGood First IssueWell scoped, documented and has the green lightWell scoped, documented and has the green lightHelp WantedYou can do thisYou can do thisSpecIssues related to the TypeScript language specificationIssues related to the TypeScript language specificationSuggestionAn idea for TypeScriptAn idea for TypeScript
Milestone
Description
I have a method declared as stop(): void|Promise<void> {} which get the error
A function whose declared type is neither 'void' nor 'any' must return a value
As void is a valid return type I would expect that to be fully valid code. Specifying only void is working.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
FixedA PR has been merged for this issueA PR has been merged for this issueGood First IssueWell scoped, documented and has the green lightWell scoped, documented and has the green lightHelp WantedYou can do thisYou can do thisSpecIssues related to the TypeScript language specificationIssues related to the TypeScript language specificationSuggestionAn idea for TypeScriptAn idea for TypeScript