-
Notifications
You must be signed in to change notification settings - Fork 12.9k
Closed
Labels
SpecIssues related to the TypeScript language specificationIssues related to the TypeScript language specification
Description
The comparability and assignment compatibility rules differ only in that
- a union type is comparable to a target type if any of its constituents, rather than all of its constituents, are comparable to that target type,
- whether a type is considered weak has no bearing on whether two types are comparable,
- whether an object type has excess properties has no bearing on whether two types are comparable,
- an object type with some optional property is comparable to an object type containing a property of the same name if it has a compatible type, regardless of whether that property is optional, and
- when relating any two signatures, each signature is always instantiated using type Any for all type arguments.
Metadata
Metadata
Assignees
Labels
SpecIssues related to the TypeScript language specificationIssues related to the TypeScript language specification