1 type derived from SyntaxDiagnosticInfo
Microsoft.CodeAnalysis.CSharp (1)
Errors\XmlSyntaxDiagnosticInfo.cs (1)
11
internal sealed class XmlSyntaxDiagnosticInfo :
SyntaxDiagnosticInfo
17 instantiations of SyntaxDiagnosticInfo
Microsoft.CodeAnalysis.CSharp (17)
Errors\SyntaxDiagnosticInfo.cs (1)
52
return new
SyntaxDiagnosticInfo
(this, severity);
Parser\AbstractLexer.cs (4)
117
return new
SyntaxDiagnosticInfo
(offset, width, code);
123
return new
SyntaxDiagnosticInfo
(offset, width, code, args);
139
return new
SyntaxDiagnosticInfo
(code);
144
return new
SyntaxDiagnosticInfo
(code, args);
Parser\DocumentationCommentParser.cs (4)
1007
SyntaxDiagnosticInfo rawInfo = new
SyntaxDiagnosticInfo
(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1054
SyntaxDiagnosticInfo rawInfo = new
SyntaxDiagnosticInfo
(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1097
SyntaxDiagnosticInfo rawInfo = new
SyntaxDiagnosticInfo
(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1305
new
SyntaxDiagnosticInfo
(ErrorCode.ERR_TypeParamMustBeIdentifier), $"{(int)ErrorCode.ERR_TypeParamMustBeIdentifier:d4}");
Parser\Lexer.cs (1)
4809
return new
SyntaxDiagnosticInfo
(start - TextWindow.LexemeStartPosition,
Parser\SyntaxParser.cs (7)
662
return new
SyntaxDiagnosticInfo
(offset, width, code, SyntaxFacts.GetText(expected));
666
return new
SyntaxDiagnosticInfo
(offset, width, code, /*unused*/string.Empty, SyntaxFacts.GetText(actual));
670
return new
SyntaxDiagnosticInfo
(offset, width, code);
875
return new
SyntaxDiagnosticInfo
(offset, width, code);
880
return new
SyntaxDiagnosticInfo
(offset, width, code, args);
885
return new
SyntaxDiagnosticInfo
(node.GetLeadingTriviaWidth(), node.Width, code, args);
890
return new
SyntaxDiagnosticInfo
(code, args);
67 references to SyntaxDiagnosticInfo
Microsoft.CodeAnalysis.CSharp (67)
Errors\SyntaxDiagnosticInfo.cs (2)
39
public
SyntaxDiagnosticInfo
WithOffset(int offset)
44
protected SyntaxDiagnosticInfo(
SyntaxDiagnosticInfo
original, DiagnosticSeverity severity) : base(original, severity)
Parser\AbstractLexer.cs (9)
17
private List<
SyntaxDiagnosticInfo
>? _errors;
40
protected
SyntaxDiagnosticInfo
[]? GetErrors(int leadingTriviaWidth)
46
var array = new
SyntaxDiagnosticInfo
[_errors.Count];
101
protected void AddError(
SyntaxDiagnosticInfo
? error)
107
_errors = new List<
SyntaxDiagnosticInfo
>(8);
114
protected
SyntaxDiagnosticInfo
MakeError(int position, int width, ErrorCode code)
120
protected
SyntaxDiagnosticInfo
MakeError(int position, int width, ErrorCode code, params object[] args)
137
protected static
SyntaxDiagnosticInfo
MakeError(ErrorCode code)
142
protected static
SyntaxDiagnosticInfo
MakeError(ErrorCode code, params object[] args)
Parser\DocumentationCommentParser.cs (10)
790
protected override
SyntaxDiagnosticInfo
GetExpectedTokenError(SyntaxKind expected, SyntaxKind actual, int offset, int length)
795
SyntaxDiagnosticInfo
rawInfo = base.GetExpectedTokenError(expected, actual, offset, length);
796
SyntaxDiagnosticInfo
crefInfo = new SyntaxDiagnosticInfo(rawInfo.Offset, rawInfo.Width, ErrorCode.WRN_ErrorOverride, rawInfo, rawInfo.Code);
810
protected override
SyntaxDiagnosticInfo
GetExpectedTokenError(SyntaxKind expected, SyntaxKind actual)
1007
SyntaxDiagnosticInfo
rawInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1008
SyntaxDiagnosticInfo
crefInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.WRN_ErrorOverride, rawInfo, rawInfo.Code);
1054
SyntaxDiagnosticInfo
rawInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1055
SyntaxDiagnosticInfo
crefInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.WRN_ErrorOverride, rawInfo, rawInfo.Code);
1097
SyntaxDiagnosticInfo
rawInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.ERR_OvlOperatorExpected);
1098
SyntaxDiagnosticInfo
crefInfo = new SyntaxDiagnosticInfo(offset, width, ErrorCode.WRN_ErrorOverride, rawInfo, rawInfo.Code);
Parser\LanguageParser.cs (4)
3832
SyntaxDiagnosticInfo
diagInfo = MakeError(opTokenErrorOffset, opTokenErrorWidth, ErrorCode.ERR_BadOperatorSyntax, SyntaxFacts.GetText(SyntaxKind.PlusToken));
3881
SyntaxDiagnosticInfo
diagInfo = MakeError(opTokenErrorOffset, opTokenErrorWidth, ErrorCode.ERR_OvlUnaryOperatorExpected);
3889
SyntaxDiagnosticInfo
diagInfo = MakeError(opTokenErrorOffset, opTokenErrorWidth, ErrorCode.ERR_OvlBinaryOperatorExpected);
3897
SyntaxDiagnosticInfo
diagInfo = MakeError(opTokenErrorOffset, opTokenErrorWidth, ErrorCode.ERR_OvlOperatorExpected);
Parser\LanguageParser_InterpolatedString.cs (7)
51
rescanInterpolation(out var kind, out
var
error, out var openQuoteRange, interpolations, out var closeQuoteRange);
71
void rescanInterpolation(out Lexer.InterpolatedStringKind kind, out
SyntaxDiagnosticInfo
? error, out Range openQuoteRange, ArrayBuilder<Lexer.Interpolation> interpolations, out Range closeQuoteRange)
115
var
indentationError = getInterpolationIndentationError(indentationWhitespace, interpolation);
176
SyntaxDiagnosticInfo
? indentationError = null;
277
SyntaxDiagnosticInfo
? getInterpolationIndentationError(
483
var
sd = (
SyntaxDiagnosticInfo
)info;
Parser\Lexer.cs (11)
338
private SyntaxToken Create(in TokenInfo info, SyntaxListBuilder? leading, SyntaxListBuilder? trailing,
SyntaxDiagnosticInfo
[]? errors)
712
NextCharOrUnicodeEscape(out _, out
var
error);
1560
SyntaxDiagnosticInfo
? error;
1584
SyntaxDiagnosticInfo
? error;
1722
SyntaxDiagnosticInfo
? error;
2664
SyntaxDiagnosticInfo
? error;
4567
SyntaxDiagnosticInfo
? info;
4574
private char NextCharOrUnicodeEscape(out char surrogateCharacter, out
SyntaxDiagnosticInfo
? info)
4593
private char NextUnicodeEscape(out char surrogateCharacter, out
SyntaxDiagnosticInfo
? info)
4598
private char ScanUnicodeEscape(bool peek, out char surrogateCharacter, out
SyntaxDiagnosticInfo
? info)
4807
private
SyntaxDiagnosticInfo
CreateIllegalEscapeDiagnostic(int start)
Parser\Lexer_StringLiteral.cs (5)
180
SyntaxDiagnosticInfo
? error;
273
out
var
error,
283
out
SyntaxDiagnosticInfo
? error,
347
public
SyntaxDiagnosticInfo
? Error = null;
367
private void TrySetError(
SyntaxDiagnosticInfo
error)
Parser\SyntaxParser.cs (15)
657
protected virtual
SyntaxDiagnosticInfo
GetExpectedTokenError(SyntaxKind expected, SyntaxKind actual, int offset, int width)
674
protected virtual
SyntaxDiagnosticInfo
GetExpectedTokenError(SyntaxKind expected, SyntaxKind actual)
873
protected static
SyntaxDiagnosticInfo
MakeError(int offset, int width, ErrorCode code)
878
protected static
SyntaxDiagnosticInfo
MakeError(int offset, int width, ErrorCode code, params object[] args)
883
protected static
SyntaxDiagnosticInfo
MakeError(GreenNode node, ErrorCode code, params object[] args)
888
protected static
SyntaxDiagnosticInfo
MakeError(ErrorCode code, params object[] args)
934
SyntaxDiagnosticInfo
diagnostic = null;
959
var
d = (
SyntaxDiagnosticInfo
)tokenDiagnostics[i];
969
var
existing = (
SyntaxDiagnosticInfo
)token.GetDiagnostics().FirstOrDefault();
983
var
existing = (
SyntaxDiagnosticInfo
)node.GetDiagnostics().FirstOrDefault();
1012
var
d = (
SyntaxDiagnosticInfo
)targetDiagnostics[i];
Syntax\InternalSyntax\SyntaxFirstTokenReplacer.cs (2)
72
SyntaxDiagnosticInfo
oldSyntaxDiagnostic = oldDiagnostic as
SyntaxDiagnosticInfo
;
Syntax\SyntaxTreeDiagnosticEnumerator.cs (2)
54
var
sdi = (
SyntaxDiagnosticInfo
)diags[diagIndex];