112 references to ERR_UnexpectedCharacter
Microsoft.CodeAnalysis.CSharp (6)
Errors\ErrorFacts.cs (1)
1115
case ErrorCode.
ERR_UnexpectedCharacter
:
Parser\Lexer.cs (4)
928
this.AddError(ErrorCode.
ERR_UnexpectedCharacter
, info.Text);
4062
this.AddCrefError(ErrorCode.
ERR_UnexpectedCharacter
, ".");
4208
this.AddCrefError(ErrorCode.
ERR_UnexpectedCharacter
, info.Text);
4219
this.AddCrefError(ErrorCode.
ERR_UnexpectedCharacter
, info.Text);
Parser\Lexer_StringLiteral.cs (1)
975
_lexer.TextWindow.Position, 1, ErrorCode.
ERR_UnexpectedCharacter
, ch));
Microsoft.CodeAnalysis.CSharp.ExpressionEvaluator.ExpressionCompiler (1)
Symbols\EEMethodSymbol.cs (1)
521
diagnostics.Add(ErrorCode.
ERR_UnexpectedCharacter
, local.Locations[0], name[0]);
Microsoft.CodeAnalysis.CSharp.Semantic.UnitTests (1)
Semantics\InterpolationTests.cs (1)
438
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "{").WithArguments("{").WithLocation(6, 33)
Microsoft.CodeAnalysis.CSharp.Symbol.UnitTests (2)
Symbols\SymbolErrorTests.cs (2)
21410
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("\\u0060").WithLocation(3, 7),
21437
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("\\u007c").WithLocation(3, 7),
Microsoft.CodeAnalysis.CSharp.Syntax.UnitTests (102)
LexicalAndXml\LexicalErrorTests.cs (5)
349
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\"),
352
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u070F"),
373
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u005C").WithLocation(1, 8));
389
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u0060"));
444
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u0303"));
LexicalAndXml\LexicalTests.cs (1)
1188
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, errors[0].Code);
Parsing\ExpressionParsingTests.cs (2)
6575
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("\\").WithLocation(7, 34),
6581
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("\\").WithLocation(7, 36),
Parsing\ParserErrorMessageTests.cs (6)
2050
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u0"),
2056
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u00"),
2062
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u000"),
2071
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u0"),
2077
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u00"),
2083
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u000"),
Parsing\ParsingErrorRecoveryTests.cs (81)
83
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
192
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
207
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
223
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
254
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
272
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
).WithArguments("$"),
355
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
369
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
412
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
451
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
466
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
607
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
768
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
782
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
797
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
812
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1083
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[3].Code);
1099
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[2].Code);
1114
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1128
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1143
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1158
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1172
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1187
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1431
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1450
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1470
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1632
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1650
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
1667
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1686
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[2].Code);
1983
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
1988
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("$").WithLocation(1, 21),
2015
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
2032
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2051
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[2].Code);
2451
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2466
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
2480
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2496
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[2].Code);
2510
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2524
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2538
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2552
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2566
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2580
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2594
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2610
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
2713
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2730
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2747
Assert.Equal(ErrorCode.
ERR_UnexpectedCharacter
, (ErrorCode)file.Errors()[1].Code); //didn't expect '$'
2764
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2780
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
2796
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3093
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3114
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3135
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3156
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3177
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3198
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3219
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3243
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3266
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3289
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3313
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
3575
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3599
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3623
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
3648
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
4739
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
4766
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
4793
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
4821
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
4848
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
4875
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
5219
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
5246
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
5273
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
5301
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[1].Code);
5328
Assert.Equal((int)ErrorCode.
ERR_UnexpectedCharacter
, file.Errors()[0].Code);
5358
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("$").WithLocation(1, 45));
Parsing\RawInterpolatedStringLiteralCompilingTests.cs (4)
688
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("#").WithLocation(5, 1),
691
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("#").WithLocation(7, 1));
717
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("#").WithLocation(5, 1),
720
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("#").WithLocation(7, 1));
Parsing\RawInterpolatedStringLiteralParsingTests.cs (1)
1729
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments("$").WithLocation(6, 17));
Parsing\ScriptParsingTests.cs (1)
9469
new ErrorDescription { Code = (int)ErrorCode.
ERR_UnexpectedCharacter
, Line = 2, Column = 3 });
Parsing\TopLevelStatementsParsingTests.cs (1)
338
Diagnostic(ErrorCode.
ERR_UnexpectedCharacter
, "").WithArguments(@"\u005C").WithLocation(1, 8)