2018-01-04 19:55:41 +01:00
|
|
|
/// <reference path="fourslash.ts" />
|
|
|
|
// @Filename: test.ts
|
|
|
|
//// interface A { a: A }
|
|
|
|
//// declare let a: A;
|
|
|
|
//// type Deep<T> = { [K in keyof T]: Deep<T[K]> }
|
|
|
|
//// declare function foo<T>(deep: Deep<T>): T;
|
|
|
|
//// const out/*1*/ = foo/*2*/(a);
|
|
|
|
//// out.a/*3*/
|
|
|
|
//// out.a.a/*4*/
|
|
|
|
//// out.a.a.a.a.a.a.a/*5*/
|
|
|
|
////
|
|
|
|
//// interface B { [s: string]: B }
|
|
|
|
//// declare let b: B;
|
|
|
|
//// const oub/*6*/ = foo/*7*/(b);
|
|
|
|
//// oub.b/*8*/
|
|
|
|
//// oub.b.b/*9*/
|
|
|
|
//// oub.b.a.n.a.n.a/*10*/
|
|
|
|
|
|
|
|
verify.quickInfoAt('1', `const out: {
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('2', `function foo<{
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}>(deep: Deep<{
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}>): {
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('3', `(property) a: {
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('4', `(property) a: {
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('5', `(property) a: {
|
2018-02-08 22:35:00 +01:00
|
|
|
a: {
|
2018-11-13 03:50:08 +01:00
|
|
|
a: ...;
|
2018-02-08 22:35:00 +01:00
|
|
|
};
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('6', `const oub: {
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('7', `function foo<{
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}>(deep: Deep<{
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}>): {
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('8', `{
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('9', `{
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|
|
|
|
verify.quickInfoAt('10', `{
|
2018-11-13 03:50:08 +01:00
|
|
|
[x: string]: ...;
|
2018-01-04 19:55:41 +01:00
|
|
|
}`);
|