* 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
72 lines
931 B
Text
72 lines
931 B
Text
=== tests/cases/compiler/forIn.ts ===
|
|
var arr = null;
|
|
>arr : any
|
|
>null : null
|
|
|
|
for (var i:number in arr) { // error
|
|
>i : string
|
|
>arr : any
|
|
|
|
var x1 = arr[i];
|
|
>x1 : any
|
|
>arr[i] : any
|
|
>arr : any
|
|
>i : string
|
|
|
|
var y1 = arr[i];
|
|
>y1 : any
|
|
>arr[i] : any
|
|
>arr : any
|
|
>i : string
|
|
}
|
|
|
|
for (var j in arr) { // ok
|
|
>j : string
|
|
>arr : any
|
|
|
|
var x2 = arr[j];
|
|
>x2 : any
|
|
>arr[j] : any
|
|
>arr : any
|
|
>j : string
|
|
|
|
var y2 = arr[j];
|
|
>y2 : any
|
|
>arr[j] : any
|
|
>arr : any
|
|
>j : string
|
|
}
|
|
|
|
var arr2 = [];
|
|
>arr2 : any[]
|
|
>[] : undefined[]
|
|
|
|
for (j in arr2) { // ok
|
|
>j : string
|
|
>arr2 : any[]
|
|
|
|
var x3 = arr2[j];
|
|
>x3 : any
|
|
>arr2[j] : any
|
|
>arr2 : any[]
|
|
>j : string
|
|
|
|
var y3 = arr2[j];
|
|
>y3 : any
|
|
>arr2[j] : any
|
|
>arr2 : any[]
|
|
>j : string
|
|
}
|
|
|
|
for (var l in arr) {
|
|
>l : string
|
|
>arr : any
|
|
|
|
// error in the body
|
|
k[l] = 1;
|
|
>k[l] = 1 : 1
|
|
>k[l] : any
|
|
>k : any
|
|
>l : string
|
|
>1 : 1
|
|
}
|