Semantics\DeconstructionTests.cs (14)
861Diagnostic(ErrorCode.ERR_IllegalStatement, "(a) => a").WithLocation(6, 9)
885Diagnostic(ErrorCode.ERR_IllegalStatement, "(a, b) => { }").WithLocation(6, 19)
4213Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(6, 9),
4357Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (a,b), var c, int d)").WithLocation(2, 1)
4485Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(6, 9)
4613Diagnostic(ErrorCode.ERR_IllegalStatement, "(var (_, _), var _, int _)").WithLocation(2, 1)
5162Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(6, 9),
5315Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (a,b), var c), int d)").WithLocation(2, 1)
5456Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(6, 9)
5593Diagnostic(ErrorCode.ERR_IllegalStatement, "((var (_, _), var _), int _)").WithLocation(2, 1)
5630Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(6, 9),
5749Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((a,b), c), int d)").WithLocation(2, 1)
5856Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(6, 9)
5956Diagnostic(ErrorCode.ERR_IllegalStatement, "(var ((_, _), _), int _)").WithLocation(2, 1)
Semantics\LambdaTests.cs (5)
208Diagnostic(ErrorCode.ERR_IllegalStatement, "1").WithLocation(54, 26),
699Diagnostic(ErrorCode.ERR_IllegalStatement, "1 / 0").WithLocation(9, 32),
752Diagnostic(ErrorCode.ERR_IllegalStatement, "new D(() => { })"),
755Diagnostic(ErrorCode.ERR_IllegalStatement, "new D(()=>{})"));
1459Diagnostic(ErrorCode.ERR_IllegalStatement, "(new object())").WithLocation(6, 41));
Semantics\NullableReferenceTypesTests.cs (7)
3396Diagnostic(ErrorCode.ERR_IllegalStatement, "new object[](x)!").WithLocation(8, 43),
3429Diagnostic(ErrorCode.ERR_IllegalStatement, "x!").WithLocation(6, 9),
3435Diagnostic(ErrorCode.ERR_IllegalStatement, "M2(x)!").WithLocation(7, 9),
3441Diagnostic(ErrorCode.ERR_IllegalStatement, "x!").WithLocation(11, 9),
3447Diagnostic(ErrorCode.ERR_IllegalStatement, "M(x)!").WithLocation(12, 9)
3676Diagnostic(ErrorCode.ERR_IllegalStatement, "i.").WithLocation(7, 31)
3748Diagnostic(ErrorCode.ERR_IllegalStatement, "(throw null!)!").WithLocation(5, 9),
Semantics\OutVarTests.cs (4)
9046Diagnostic(ErrorCode.ERR_IllegalStatement, "let").WithLocation(12, 23),
9061Diagnostic(ErrorCode.ERR_IllegalStatement, "let").WithLocation(17, 23),
9104Diagnostic(ErrorCode.ERR_IllegalStatement, "let").WithLocation(12, 23),
9119Diagnostic(ErrorCode.ERR_IllegalStatement, "let").WithLocation(17, 23),
Semantics\SemanticErrorTests.cs (12)
7838Diagnostic(ErrorCode.ERR_IllegalStatement, "checked(i++)"));
7858Diagnostic(ErrorCode.ERR_IllegalStatement, "(a) => a").WithLocation(6, 9),
7861Diagnostic(ErrorCode.ERR_IllegalStatement, "(a, b) => { }").WithLocation(7, 9),
7864Diagnostic(ErrorCode.ERR_IllegalStatement, "x + y").WithLocation(9, 9),
7867Diagnostic(ErrorCode.ERR_IllegalStatement, "x == 1").WithLocation(9, 16),
7892Diagnostic(ErrorCode.ERR_IllegalStatement, "(a) => a").WithLocation(6, 9),
7895Diagnostic(ErrorCode.ERR_IllegalStatement, "(a, b) => { }").WithLocation(7, 9),
7898Diagnostic(ErrorCode.ERR_IllegalStatement, "x + y").WithLocation(9, 9),
7901Diagnostic(ErrorCode.ERR_IllegalStatement, "x == 1").WithLocation(9, 16),
24413Diagnostic(ErrorCode.ERR_IllegalStatement, "x?.Length").WithLocation(8, 9),
24416Diagnostic(ErrorCode.ERR_IllegalStatement, "x?[1]").WithLocation(9, 9),
24419Diagnostic(ErrorCode.ERR_IllegalStatement, "x?.ToString()[1]").WithLocation(10, 9)