TypeScript/tests/cases/compiler/sigantureIsSubTypeIfTheyAreIdentical.ts

8 lines
220 B
TypeScript
Raw Normal View History

2014-07-13 01:04:16 +02:00
interface ICache {
get<T>(key: string): T;
}
class CacheService implements ICache { // Should not error that property type of get are incomaptible
get<T>(key: string): T {
return undefined;
}
}