1 write to Text
Microsoft.CodeAnalysis.Features (1)
EmbeddedLanguages\Json\JsonLexer.cs (1)
28Text = text;
22 references to Text
Microsoft.CodeAnalysis.Features (22)
EmbeddedLanguages\Json\JsonLexer.cs (18)
31public readonly VirtualChar CurrentChar => Text[Position]; 37=> Text[start..end]; 42if (Position == Text.Length) 62Debug.Assert(Position < Text.Length); 91while (Position < Text.Length) 124if (this.Position == Text.Length) 144for (var i = 0; this.Position < Text.Length && i < 4; i++) 170while (Position < Text.Length && !IsNotPartOfText(this.CurrentChar)) 189var chars = this.Text[Position..(Position + 1)]; 198while (Position < Text.Length) 281while (Position < Text.Length && this.CurrentChar.Value is not '\r' and not '\n') 302while (Position < Text.Length && !IsAt("*/")) 311Debug.Assert(Position == Text.Length); 317=> TextSpan.FromBounds(Text[startInclusive].Span.Start, Text[endExclusive - 1].Span.End); 326if (position + i >= Text.Length || Text[position + i] != val[i]) 336while (Position < Text.Length && char.IsWhiteSpace(this.CurrentChar))
EmbeddedLanguages\Json\JsonParser.cs (4)
123Debug.Assert(_lexer.Position == _lexer.Text.Length); 134var diagnostic2 = CheckTopLevel(_lexer.Text, root); 141return new JsonTree(_lexer.Text, root, diagnostic == null 591? new TextSpan(_lexer.Text[^1].Span.End, 0)