TypeScript/tests/baselines/reference/null.errors.txt
2017-01-13 15:06:24 -08:00

28 lines
526 B
Plaintext

tests/cases/compiler/null.ts(4,9): error TS2531: Object is possibly 'null'.
==== tests/cases/compiler/null.ts (1 errors) ====
var x=null;
var y=3+x;
var z=3+null;
~~~~
!!! error TS2531: Object is possibly 'null'.
class C {
}
function f() {
return null;
return new C();
}
function g() {
return null;
return 3;
}
interface I {
x:any;
y:number;
}
var w:I={x:null,y:3};