16 lines
670 B
Plaintext
16 lines
670 B
Plaintext
==== tests/cases/conformance/interfaces/interfaceDeclarations/interfaceThatHidesBaseProperty2.ts (1 errors) ====
|
|
interface Base {
|
|
x: { a: number };
|
|
}
|
|
|
|
interface Derived extends Base { // error
|
|
~~~~~~~
|
|
!!! error TS2429: Interface 'Derived' incorrectly extends interface 'Base':
|
|
!!! error TS2429: Types of property 'x' are incompatible:
|
|
!!! error TS2429: Type '{ a: string; }' is not assignable to type '{ a: number; }':
|
|
!!! error TS2429: Types of property 'a' are incompatible:
|
|
!!! error TS2429: Type 'string' is not assignable to type 'number'.
|
|
x: {
|
|
a: string;
|
|
};
|
|
} |