Files
tsgo/testdata/baselines/reference/submodule/conformance/additionOperatorWithOnlyNullValueOrUndefinedValue.errors.txt

32 lines
1.8 KiB
Plaintext

additionOperatorWithOnlyNullValueOrUndefinedValue.ts(2,10): error TS18050: The value 'null' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(2,17): error TS18050: The value 'null' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(3,10): error TS18050: The value 'null' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(3,17): error TS18050: The value 'undefined' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(4,10): error TS18050: The value 'undefined' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(4,22): error TS18050: The value 'null' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(5,10): error TS18050: The value 'undefined' cannot be used here.
additionOperatorWithOnlyNullValueOrUndefinedValue.ts(5,22): error TS18050: The value 'undefined' cannot be used here.
==== additionOperatorWithOnlyNullValueOrUndefinedValue.ts (8 errors) ====
// bug 819721
var r1 = null + null;
~~~~
!!! error TS18050: The value 'null' cannot be used here.
~~~~
!!! error TS18050: The value 'null' cannot be used here.
var r2 = null + undefined;
~~~~
!!! error TS18050: The value 'null' cannot be used here.
~~~~~~~~~
!!! error TS18050: The value 'undefined' cannot be used here.
var r3 = undefined + null;
~~~~~~~~~
!!! error TS18050: The value 'undefined' cannot be used here.
~~~~
!!! error TS18050: The value 'null' cannot be used here.
var r4 = undefined + undefined;
~~~~~~~~~
!!! error TS18050: The value 'undefined' cannot be used here.
~~~~~~~~~
!!! error TS18050: The value 'undefined' cannot be used here.