46 references to GetSpan
Microsoft.CodeAnalysis.Features (46)
EmbeddedLanguages\Json\JsonParser.cs (5)
185firstToken.GetSpan()); 197emptyValue.CommaToken.GetSpan()); 204propertyValue.ColonToken.GetSpan()); 245((JsonPropertyNode)child).ColonToken.GetSpan()); 444nestedProperty.ColonToken.GetSpan())),
EmbeddedLanguages\Json\JsonParser.JsonNetSyntaxChecks.cs (4)
145? new EmbeddedDiagnostic(FeaturesResources.Invalid_constructor_name, node.NameToken.GetSpan()) 168return new EmbeddedDiagnostic(string.Format(FeaturesResources._0_expected, ','), GetFirstToken(nextChild).GetSpan()); 179return new EmbeddedDiagnostic(FeaturesResources.Only_properties_allowed_in_an_object, GetFirstToken(child).GetSpan()); 187? new EmbeddedDiagnostic(FeaturesResources.Invalid_property_name, node.NameToken.GetSpan())
EmbeddedLanguages\Json\JsonParser.StrictSyntaxChecker.cs (7)
115return new EmbeddedDiagnostic(FeaturesResources.Only_properties_allowed_in_an_object, GetFirstToken(child).GetSpan()); 119return new EmbeddedDiagnostic(FeaturesResources.Trailing_comma_not_allowed, node.Sequence.NodesAndTokens[^1].Token.GetSpan()); 143return new EmbeddedDiagnostic(string.Format(FeaturesResources._0_expected, ","), GetFirstToken(child).GetSpan()); 156return new EmbeddedDiagnostic(FeaturesResources.Property_name_must_be_a_string, node.NameToken.GetSpan()); 221? new EmbeddedDiagnostic(FeaturesResources.Invalid_number, literalToken.GetSpan()) 258=> new(string.Format(FeaturesResources._0_literal_not_allowed, literalToken.VirtualChars.CreateString()), literalToken.GetSpan()); 264=> new(FeaturesResources.Constructors_not_allowed, node.NewKeyword.GetSpan());
EmbeddedLanguages\Json\LanguageServices\JsonBraceMatcher.cs (2)
110: new BraceMatchingResult(open.GetSpan(), close.GetSpan());
EmbeddedLanguages\Json\LanguageServices\JsonClassifier.cs (2)
98context.AddClassification(ClassificationTypeNames.JsonPunctuation, token.GetSpan()); 123Context.AddClassification(typeName, token.GetSpan());
EmbeddedLanguages\RegularExpressions\LanguageServices\RegexClassifier.cs (1)
111Context.AddClassification(typeName, token.GetSpan());
EmbeddedLanguages\RegularExpressions\RegexLexer.cs (2)
247token.GetSpan())); 301token.GetSpan()));
EmbeddedLanguages\RegularExpressions\RegexParser.cs (23)
277barToken.GetSpan())); 569secondNumberTokenLocal.GetSpan())); 632new EmbeddedDiagnostic(FeaturesResources.Too_many_close_parens, _currentToken.GetSpan())); 727: token.GetSpan(); 785openParenToken.GetSpan())); 830capture.GetSpan())); 838capture.GetSpan())); 916openParenToken.GetSpan())); 923openParenToken.GetSpan())); 932openParenToken.GetSpan())); 1030capture.GetSpan())); 1070_currentToken.GetSpan())); 1130captureToken.GetSpan())); 1140captureToken.GetSpan())); 1186new EmbeddedDiagnostic(FeaturesResources.Unrecognized_grouping_construct, openParenToken.GetSpan()))); 1331minusToken.GetSpan())); 1593backslashToken.GetSpan())); 1639backslashToken.GetSpan())); 1869typeToken.GetSpan())); 1901typeToken.GetSpan())); 1941_currentToken.GetSpan())); 2036string.Format(FeaturesResources.Quantifier_0_following_nothing, token.VirtualChars[0]), token.GetSpan())); 2041string.Format(FeaturesResources.Nested_quantifier_0, token.VirtualChars[0]), token.GetSpan()));