13 instantiations of VirtualCharGreen
Roslyn.Diagnostics.Analyzers (5)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\AbstractVirtualCharService.cs (3)
166result.Add(new VirtualCharGreen('"', offset: index, width: 2)); 175result.Add(new VirtualCharGreen(tokenText[index], offset: index, width: width)); 201result.Add(new VirtualCharGreen(ch, offset: index, width: 1));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\VirtualChar.cs (1)
59=> new(this.Char, offset, this.Width);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\VirtualCharGreenSequence.Chunks.cs (1)
87=> new(data[index], offset: index, width: 1);
Roslyn.Diagnostics.CSharp.Analyzers (8)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\EmbeddedLanguages\VirtualChars\CSharpVirtualCharService.cs (8)
274charResults.Add(new VirtualCharGreen(ch, index, braceWidth)); 279charResults.Add(new VirtualCharGreen(ch, index, width: 1)); 351result.Add(new VirtualCharGreen(ch, offset: index, width: 2)); 423result.Add(new VirtualCharGreen((char)uintChar, offset: startIndex, width: 2 + 8)); 435result.Add(new VirtualCharGreen((char)highSurrogate, offset: startIndex, width: prefix.Length)); 436result.Add(new VirtualCharGreen((char)lowSurrogate, offset: startIndex + prefix.Length, width: 4)); 466result.Add(new VirtualCharGreen(character, offset: startIndex, width)); 497result.Add(new VirtualCharGreen(character, offset: startIndex, width));
27 references to VirtualCharGreen
Roslyn.Diagnostics.Analyzers (19)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\AbstractVirtualCharService.cs (5)
160var result = ImmutableSegmentedList.CreateBuilder<VirtualCharGreen>(); 190protected static int ConvertTextAtIndexToVirtualChar(string tokenText, int index, ImmutableSegmentedList<VirtualCharGreen>.Builder result) 193protected static int ConvertTextAtIndexToVirtualChar(SourceText tokenText, int index, ImmutableSegmentedList<VirtualCharGreen>.Builder result) 197T tokenText, int index, TTextInfo info, ImmutableSegmentedList<VirtualCharGreen>.Builder result) 212ImmutableSegmentedList<VirtualCharGreen>.Builder result)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\VirtualChar.cs (7)
12/// <see cref="VirtualCharGreen"/> provides a uniform view of a language's string token characters regardless if they 16/// <c>t</c>). <see cref="VirtualCharGreen"/> will represent both, providing the raw <see cref="char"/> value of 39/// The width of characters in the original <see cref="SourceText"/> that represent this <see cref="VirtualCharGreen"/>. 58public VirtualCharGreen WithOffset(int offset) 79public VirtualChar(VirtualCharGreen green, int tokenStart) 87internal VirtualCharGreen Green { get; } 93/// <inheritdoc cref="VirtualCharGreen.Char"/>
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\VirtualCharGreenSequence.Chunks.cs (4)
22public abstract VirtualCharGreen this[int index] { get; } 31private sealed class ImmutableSegmentedListChunk(ImmutableSegmentedList<VirtualCharGreen> array) : Chunk 34public override VirtualCharGreen this[int index] => array[index]; 86public override VirtualCharGreen this[int index]
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\EmbeddedLanguages\VirtualChars\VirtualCharSequence.cs (3)
33public static readonly VirtualCharGreenSequence Empty = Create(ImmutableSegmentedList<VirtualCharGreen>.Empty); 35public static VirtualCharGreenSequence Create(ImmutableSegmentedList<VirtualCharGreen> virtualChars) 77public VirtualCharGreen this[int index] => _leafCharacters[_span.Start + index];
Roslyn.Diagnostics.CSharp.Analyzers (8)
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\CSharp\EmbeddedLanguages\VirtualChars\CSharpVirtualCharService.cs (8)
25private static readonly ObjectPool<ImmutableSegmentedList<VirtualCharGreen>.Builder> s_pooledBuilders = new(() => ImmutableSegmentedList.CreateBuilder<VirtualCharGreen>()); 133var result = ImmutableSegmentedList.CreateBuilder<VirtualCharGreen>(); 201var result = ImmutableSegmentedList.CreateBuilder<VirtualCharGreen>(); 306ImmutableSegmentedList<VirtualCharGreen>.Builder result, 322ImmutableSegmentedList<VirtualCharGreen>.Builder result, string tokenText, int index) 357ImmutableSegmentedList<VirtualCharGreen>.Builder result, string tokenText, int index) 377ImmutableSegmentedList<VirtualCharGreen>.Builder result,