* Always generate type & symbol baselines * Accept changed shadowed baselines * Accept brand new type and symbol baselines * Allow `getTypeAtLocation` to return undefined in the type writer * Accept baselines which had missing type information * Bind container for dynamically names enum members so they may be printed * Accept type/symbol baselines for enums with computed members * First pass at reducing typeWriter memory overhead * Use generators to allow for type and symbol baselines with no cache * Accept new baselines for tests whose output was fixed by better newline splitting * Hard cap on number of declarations printed, cache declaration print text * handle differing newlines better still to handle RWC newlines * Lower abridging count, accept abridged baselines * Limit max RWC error output size, limit RWC type and symbol baseline input size * Move skip logic into type and symbol baseliner to streamline error handling * Accept removal of empty baselines * Canonicalize path earlier to handle odd paths in input files * Do canonicalization earlier still, also ensure parallel perf profiles for different targets do not trample one another * No need to pathify again
95 lines
2.7 KiB
Text
95 lines
2.7 KiB
Text
=== tests/cases/compiler/typeofProperty.ts ===
|
|
interface I1 {
|
|
>I1 : Symbol(I1, Decl(typeofProperty.ts, 0, 0))
|
|
|
|
a: number;
|
|
>a : Symbol(I1.a, Decl(typeofProperty.ts, 0, 14))
|
|
|
|
b: typeof a; // Should yield error (a is not a value)
|
|
>b : Symbol(I1.b, Decl(typeofProperty.ts, 1, 14))
|
|
}
|
|
|
|
interface I2 {
|
|
>I2 : Symbol(I2, Decl(typeofProperty.ts, 3, 1))
|
|
|
|
c: typeof d; // Should yield error (d is not a value)
|
|
>c : Symbol(I2.c, Decl(typeofProperty.ts, 5, 14))
|
|
|
|
d: string;
|
|
>d : Symbol(I2.d, Decl(typeofProperty.ts, 6, 16))
|
|
}
|
|
|
|
interface I3 {
|
|
>I3 : Symbol(I3, Decl(typeofProperty.ts, 8, 1))
|
|
|
|
e: typeof e; // Should yield error (e is not a value)
|
|
>e : Symbol(I3.e, Decl(typeofProperty.ts, 10, 14))
|
|
}
|
|
|
|
class C1 {
|
|
>C1 : Symbol(C1, Decl(typeofProperty.ts, 12, 1))
|
|
|
|
a: number;
|
|
>a : Symbol(C1.a, Decl(typeofProperty.ts, 14, 10))
|
|
|
|
b: typeof a; // Should yield error (a is not a value)
|
|
>b : Symbol(C1.b, Decl(typeofProperty.ts, 15, 14))
|
|
}
|
|
|
|
|
|
class C2 {
|
|
>C2 : Symbol(C2, Decl(typeofProperty.ts, 17, 1))
|
|
|
|
c: typeof d; // Should yield error (d is not a value)
|
|
>c : Symbol(C2.c, Decl(typeofProperty.ts, 20, 10))
|
|
|
|
d: string;
|
|
>d : Symbol(C2.d, Decl(typeofProperty.ts, 21, 16))
|
|
}
|
|
|
|
class C3 {
|
|
>C3 : Symbol(C3, Decl(typeofProperty.ts, 23, 1))
|
|
|
|
e: typeof e; // Should yield error (e is not a value)
|
|
>e : Symbol(C3.e, Decl(typeofProperty.ts, 25, 10))
|
|
}
|
|
|
|
|
|
|
|
interface ValidInterface {
|
|
>ValidInterface : Symbol(ValidInterface, Decl(typeofProperty.ts, 27, 1))
|
|
|
|
x: string;
|
|
>x : Symbol(ValidInterface.x, Decl(typeofProperty.ts, 31, 26))
|
|
}
|
|
|
|
class ValidClass implements ValidInterface {
|
|
>ValidClass : Symbol(ValidClass, Decl(typeofProperty.ts, 33, 1))
|
|
>ValidInterface : Symbol(ValidInterface, Decl(typeofProperty.ts, 27, 1))
|
|
|
|
x: string;
|
|
>x : Symbol(ValidClass.x, Decl(typeofProperty.ts, 35, 44))
|
|
}
|
|
|
|
var vcInstance = new ValidClass();
|
|
>vcInstance : Symbol(vcInstance, Decl(typeofProperty.ts, 39, 3))
|
|
>ValidClass : Symbol(ValidClass, Decl(typeofProperty.ts, 33, 1))
|
|
|
|
var viInstance = vcInstance;
|
|
>viInstance : Symbol(viInstance, Decl(typeofProperty.ts, 40, 3))
|
|
>vcInstance : Symbol(vcInstance, Decl(typeofProperty.ts, 39, 3))
|
|
|
|
var x1: typeof vcInstance.x; // x1: string
|
|
>x1 : Symbol(x1, Decl(typeofProperty.ts, 42, 3))
|
|
>vcInstance.x : Symbol(ValidClass.x, Decl(typeofProperty.ts, 35, 44))
|
|
>vcInstance : Symbol(vcInstance, Decl(typeofProperty.ts, 39, 3))
|
|
>x : Symbol(ValidClass.x, Decl(typeofProperty.ts, 35, 44))
|
|
|
|
var x2: typeof viInstance.x; // x2: string
|
|
>x2 : Symbol(x2, Decl(typeofProperty.ts, 43, 3))
|
|
>viInstance.x : Symbol(ValidClass.x, Decl(typeofProperty.ts, 35, 44))
|
|
>viInstance : Symbol(viInstance, Decl(typeofProperty.ts, 40, 3))
|
|
>x : Symbol(ValidClass.x, Decl(typeofProperty.ts, 35, 44))
|
|
|
|
|
|
|