-
Notifications
You must be signed in to change notification settings - Fork 13k
Closed
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingGood First IssueWell scoped, documented and has the green lightWell scoped, documented and has the green lightHelp WantedYou can do thisYou can do this
Description
declare class Container<T> {
filter<U extends T>(predicate: (x: T) => x is U): Container<U>;
}
interface Animal {
a
}
interface Dog extends Animal {
d
}
declare function isDog(x: Animal): boolean;
new Container<Animal>().filter(isDog);
// ~~~~~
Expected: Signature '(x: Animal): boolean' must be a type predicate.
Actual: Signature '(x: Animal): boolean' must have a type predicate.
Metadata
Metadata
Assignees
Labels
BugA bug in TypeScriptA bug in TypeScriptDomain: Error MessagesThe issue relates to error messagingThe issue relates to error messagingGood First IssueWell scoped, documented and has the green lightWell scoped, documented and has the green lightHelp WantedYou can do thisYou can do this