TypeScript/tests/cases/compiler/circularConstraintYieldsAppropriateError.ts
Wesley Wigham cedcba9285
Reset partial memberlist on defered circularity to calculate the correct members (#20179)
* Reset partial memberlist on defered circularity to calculate the correct members

* Remove return type
2017-12-22 11:41:39 -08:00

17 lines
324 B
TypeScript

// https://github.com/Microsoft/TypeScript/issues/16861
class BaseType<T> {
bar: T
}
class NextType<C extends { someProp: any }, T = C['someProp']> extends BaseType<T> {
baz: string;
}
class Foo extends NextType<Foo> {
someProp: {
test: true
}
}
const foo = new Foo();
foo.bar.test