TypeScript/tests/baselines/reference/cannotInvokeNewOnErrorExpression.errors.txt
Cyrus Najmabadi f1a2e41a8a Sort diagnostics in our baseline output.
This was we don't get noisy baselines just because a different phase of the compiler reported
the diagnostic.

This helps with Yui's refactoring work to move grammar checks into the type checker.
2014-12-16 15:56:56 -08:00

14 lines
669 B
Plaintext

tests/cases/compiler/cannotInvokeNewOnErrorExpression.ts(5,15): error TS2339: Property 'ClassA' does not exist on type 'typeof M'.
tests/cases/compiler/cannotInvokeNewOnErrorExpression.ts(5,21): error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.
==== tests/cases/compiler/cannotInvokeNewOnErrorExpression.ts (2 errors) ====
module M
{
class ClassA {}
}
var t = new M.ClassA[];
~~~~~~
!!! error TS2339: Property 'ClassA' does not exist on type 'typeof M'.
~~
!!! error TS1150: 'new T[]' cannot be used to create an array. Use 'new Array<T>()' instead.