13 instantiations of ImmutableSegmentedList
Microsoft.CodeAnalysis.Workspaces (13)
188 references to ImmutableSegmentedList
Microsoft.CodeAnalysis.CSharp.Features (1)
Microsoft.CodeAnalysis.CSharp.Workspaces (1)
Microsoft.CodeAnalysis.EditorFeatures (7)
Microsoft.CodeAnalysis.EditorFeatures.Wpf (1)
Microsoft.CodeAnalysis.Features (6)
Microsoft.CodeAnalysis.LanguageServer.Protocol (2)
Microsoft.CodeAnalysis.Remote.ServiceHub (1)
Microsoft.CodeAnalysis.Workspaces (154)
AbstractVirtualCharService.cs (4)
192protected static int ConvertTextAtIndexToRune(string tokenText, int index, ImmutableSegmentedList<VirtualChar>.Builder result, int offset)
195protected static int ConvertTextAtIndexToRune(SourceText tokenText, int index, ImmutableSegmentedList<VirtualChar>.Builder result, int offset)
199T tokenText, int index, TTextInfo info, ImmutableSegmentedList<VirtualChar>.Builder result, int offset)
232ImmutableSegmentedList<VirtualChar>.Builder result)
ImmutableSegmentedList`1.cs (61)
18/// <para>There are different scenarios best for <see cref="ImmutableSegmentedList{T}"/> and others
22/// <see cref="ImmutableSegmentedList{T}"/>:</para>
27/// <description><see cref="ImmutableSegmentedList{T}"/> Complexity</description>
71internal readonly partial struct ImmutableSegmentedList<T> : IImmutableList<T>, IReadOnlyList<T>, IList<T>, IList, IEquatable<ImmutableSegmentedList<T>>
74public static readonly ImmutableSegmentedList<T> Empty = new(new SegmentedList<T>());
112public static bool operator ==(ImmutableSegmentedList<T> left, ImmutableSegmentedList<T> right)
115public static bool operator !=(ImmutableSegmentedList<T> left, ImmutableSegmentedList<T> right)
118public static bool operator ==(ImmutableSegmentedList<T>? left, ImmutableSegmentedList<T>? right)
121public static bool operator !=(ImmutableSegmentedList<T>? left, ImmutableSegmentedList<T>? right)
127var self = this;
139public ImmutableSegmentedList<T> Add(T value)
141var self = this;
159public ImmutableSegmentedList<T> AddRange(IEnumerable<T> items)
161var self = this;
169if (items is ImmutableSegmentedList<T> immutableList)
171else if (items is ImmutableSegmentedList<T>.Builder builder)
199public ImmutableSegmentedList<T> Clear()
206public ImmutableSegmentedList<TOutput> ConvertAll<TOutput>(Converter<T, TOutput> converter)
229public ImmutableSegmentedList<T> FindAll(Predicate<T> match)
255var self = this;
270var self = this;
291public ImmutableSegmentedList<T> GetRange(int index, int count)
293var self = this;
308public ImmutableSegmentedList<T> Insert(int index, T item)
310var self = this;
323public ImmutableSegmentedList<T> InsertRange(int index, IEnumerable<T> items)
325var self = this;
339var self = this;
359public ImmutableSegmentedList<T> Remove(T value)
361var self = this;
371public ImmutableSegmentedList<T> Remove(T value, IEqualityComparer<T>? equalityComparer)
373var self = this;
383public ImmutableSegmentedList<T> RemoveAll(Predicate<T> match)
393public ImmutableSegmentedList<T> RemoveAt(int index)
402public ImmutableSegmentedList<T> RemoveRange(IEnumerable<T> items)
407var self = this;
426public ImmutableSegmentedList<T> RemoveRange(IEnumerable<T> items, IEqualityComparer<T>? equalityComparer)
431var self = this;
450public ImmutableSegmentedList<T> RemoveRange(int index, int count)
452var self = this;
466public ImmutableSegmentedList<T> Replace(T oldValue, T newValue)
468var self = this;
480public ImmutableSegmentedList<T> Replace(T oldValue, T newValue, IEqualityComparer<T>? equalityComparer)
482var self = this;
494public ImmutableSegmentedList<T> Reverse()
496var self = this;
506public ImmutableSegmentedList<T> Reverse(int index, int count)
514public ImmutableSegmentedList<T> SetItem(int index, T value)
523public ImmutableSegmentedList<T> Sort()
525var self = this;
537public ImmutableSegmentedList<T> Sort(IComparer<T>? comparer)
539var self = this;
551public ImmutableSegmentedList<T> Sort(Comparison<T> comparison)
558var self = this;
570public ImmutableSegmentedList<T> Sort(int index, int count, IComparer<T>? comparer)
590return obj is ImmutableSegmentedList<T> other
594public bool Equals(ImmutableSegmentedList<T> other)
RoslynImmutableInterlocked.cs (26)
30public static bool Update<T>(ref ImmutableSegmentedList<T> location, Func<ImmutableSegmentedList<T>, ImmutableSegmentedList<T>> transformer)
35var oldValue = ImmutableSegmentedList<T>.PrivateInterlocked.VolatileRead(in location);
38var newValue = transformer(oldValue);
45var interlockedResult = InterlockedCompareExchange(ref location, newValue, oldValue);
71public static bool Update<T, TArg>(ref ImmutableSegmentedList<T> location, Func<ImmutableSegmentedList<T>, TArg, ImmutableSegmentedList<T>> transformer, TArg transformerArgument)
76var oldValue = ImmutableSegmentedList<T>.PrivateInterlocked.VolatileRead(in location);
79var newValue = transformer(oldValue, transformerArgument);
86var interlockedResult = InterlockedCompareExchange(ref location, newValue, oldValue);
102public static ImmutableSegmentedList<T> InterlockedExchange<T>(ref ImmutableSegmentedList<T> location, ImmutableSegmentedList<T> value)
104return ImmutableSegmentedList<T>.PrivateInterlocked.InterlockedExchange(ref location, value);
116public static ImmutableSegmentedList<T> InterlockedCompareExchange<T>(ref ImmutableSegmentedList<T> location, ImmutableSegmentedList<T> value, ImmutableSegmentedList<T> comparand)
118return ImmutableSegmentedList<T>.PrivateInterlocked.InterlockedCompareExchange(ref location, value, comparand);
130public static bool InterlockedInitialize<T>(ref ImmutableSegmentedList<T> location, ImmutableSegmentedList<T> value)
132return InterlockedCompareExchange(ref location, value, default(ImmutableSegmentedList<T>)).IsDefault;
Shared\Utilities\AsyncBatchingWorkQueue`1.cs (4)
19Func<ImmutableSegmentedList<TItem>, CancellationToken, ValueTask> processBatchAsync,
32Func<ImmutableSegmentedList<TItem>, CancellationToken, ValueTask> processBatchAsync,
40private static Func<ImmutableSegmentedList<TItem>, CancellationToken, ValueTask<VoidResult>> Convert(Func<ImmutableSegmentedList<TItem>, CancellationToken, ValueTask> processBatchAsync)
Microsoft.VisualStudio.LanguageServices (14)
Microsoft.VisualStudio.LanguageServices.Implementation (1)