TypeScript/tests/baselines/reference/implicitAnyAmbients.errors.txt

57 lines
2.7 KiB
Plaintext
Raw Normal View History

tests/cases/compiler/implicitAnyAmbients.ts(3,9): error TS7005: Variable 'x' implicitly has an 'any' type.
tests/cases/compiler/implicitAnyAmbients.ts(6,14): error TS7010: 'f', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(6,16): error TS7006: Parameter 'x' implicitly has an 'any' type.
tests/cases/compiler/implicitAnyAmbients.ts(7,14): error TS7010: 'f2', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(11,9): error TS7010: 'foo', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(12,9): error TS7010: 'foo2', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(17,9): error TS7010: 'foo', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(18,9): error TS7010: 'foo2', which lacks return-type annotation, implicitly has an 'any' return type.
tests/cases/compiler/implicitAnyAmbients.ts(23,13): error TS7005: Variable 'y' implicitly has an 'any' type.
2014-07-13 01:04:16 +02:00
==== tests/cases/compiler/implicitAnyAmbients.ts (9 errors) ====
declare module m {
var x; // error
~
!!! error TS7005: Variable 'x' implicitly has an 'any' type.
2014-07-13 01:04:16 +02:00
var y: any;
function f(x); // error
~
!!! error TS7010: 'f', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
~
!!! error TS7006: Parameter 'x' implicitly has an 'any' type.
2014-07-13 01:04:16 +02:00
function f2(x: any); // error
~~
!!! error TS7010: 'f2', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
function f3(x: any): any;
interface I {
foo(); // error
~~~~~~
!!! error TS7010: 'foo', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
foo2(x: any); // error
~~~~~~~~~~~~~
!!! error TS7010: 'foo2', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
foo3(x: any): any;
}
class C {
foo(); // error
~~~~~~
!!! error TS7010: 'foo', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
foo2(x: any); // error
~~~~~~~~~~~~~
!!! error TS7010: 'foo2', which lacks return-type annotation, implicitly has an 'any' return type.
2014-07-13 01:04:16 +02:00
foo3(x: any): any;
}
module n {
var y; // error
~
!!! error TS7005: Variable 'y' implicitly has an 'any' type.
2014-07-13 01:04:16 +02:00
}
import m2 = n;
}