49 references to GetChecksum
BuildValidator (1)
LocalSourceResolver.cs (1)
52if (!sourceText.GetChecksum().SequenceEqual(sourceTextInfo.Hash))
Microsoft.CodeAnalysis (9)
Compilation\DeterministicKeyBuilder.cs (1)
278WriteByteArrayValue(writer, "checksum", sourceText.GetChecksum().AsSpan());
DiagnosticAnalyzer\AdditionalTextComparer.cs (3)
50return ByteSequenceComparer.Equals(xText.GetChecksum(), yText.GetChecksum()); 56ByteSequenceComparer.GetHashCode(GetTextOrNullIfBinary(obj)?.GetChecksum() ?? ImmutableArray<byte>.Empty));
EmbeddedText.cs (2)
113return new EmbeddedText(filePath, text.GetChecksum(), text.ChecksumAlgorithm, text.PrecomputedEmbeddedTextBlob); 116return new EmbeddedText(filePath, text.GetChecksum(), text.ChecksumAlgorithm, CreateBlob(text));
Syntax\SyntaxTree.cs (1)
377ImmutableInterlocked.InterlockedInitialize(ref _lazyChecksum, text.GetChecksum());
Text\SourceText.cs (1)
41/// Backing store of <see cref="GetChecksum"/>
Text\SourceTextComparer.cs (1)
35var checksum = obj.GetChecksum();
Microsoft.CodeAnalysis.Features (2)
EditAndContinue\CommittedSolution.cs (1)
437=> checksumAlgorithm == sourceText.ChecksumAlgorithm && sourceText.GetChecksum().SequenceEqual(requiredChecksum);
PdbSourceDocument\PdbSourceDocumentLoaderService.cs (1)
197var fileChecksum = sourceText.GetChecksum();
Microsoft.CodeAnalysis.LanguageServer (1)
HostWorkspace\Razor\RazorDynamicFileInfoProvider.TextChangesTextLoader.cs (1)
69if (!sourceText.GetChecksum().SequenceEqual(_checksum))
Microsoft.CodeAnalysis.LanguageServer.Protocol (1)
Handler\SourceGenerators\SourceGeneratedDocumentCache.cs (1)
35return data is null ? Checksum.Null : Checksum.From(data.GetChecksum());
Microsoft.CodeAnalysis.Rebuild (1)
CompilationOptionsReader.cs (1)
309if (!sourceText.GetChecksum().SequenceEqual(sourceTextInfo.Hash))
Microsoft.CodeAnalysis.Rebuild.UnitTests (2)
CompilationRebuildArtifactResolver.cs (1)
32.Single(x => x.GetChecksum().SequenceEqual(sourceTextInfo.Hash));
DeterministicKeyBuilderTests.cs (1)
255var checksum = text.GetChecksum();
Microsoft.CodeAnalysis.UnitTests (28)
EmbeddedTextTests.cs (5)
150AssertEx.Equal(source.GetChecksum(), text.Checksum); 192AssertEx.Equal(source.GetChecksum(), text.Checksum); 242AssertEx.Equal(SourceText.CalculateChecksum(bytes, 0, bytes.Length, SourceHashAlgorithm.Sha1), source.GetChecksum()); 243AssertEx.Equal(source.GetChecksum(), text.Checksum); 257AssertEx.Equal(source.GetChecksum(), text.Checksum);
Text\LargeTextTests.cs (2)
338Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
Text\SourceTextTests.cs (9)
183var actualChecksum = text.GetChecksum(); 297Assert.True(sourceText1.GetChecksum().SequenceEqual(sourceText2.GetChecksum())); 308var checksum1 = sourceText1.GetChecksum(); 309var checksum2 = sourceText2.GetChecksum(); 358Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum()); 375Assert.Equal<byte>(expectedSourceText.GetChecksum(), actualSourceText.GetChecksum());
Text\StringTextDecodingTests.cs (7)
81var checksum = data.GetChecksum(); 90var checksum = data.GetChecksum(); 99var checksum = data.GetChecksum(); 109var checksum = data.GetChecksum(); 118var checksum = data.GetChecksum(); 127var checksum = data.GetChecksum(); 136var checksum = data.GetChecksum();
Text\StringTextTest.cs (5)
225var checksum = data.GetChecksum(); 237var checksum = source.GetChecksum(); 252var checksum = source.GetChecksum(); 264var checksum = source.GetChecksum(); 279var checksum = source.GetChecksum();
Microsoft.CodeAnalysis.Workspaces (2)
SourceGeneration\IRemoteSourceGenerationService.cs (1)
73/// <param name="OriginalSourceTextContentHash">Checksum originally produced from <see cref="SourceText.GetChecksum"/> on
Workspace\Solution\SourceGeneratedDocumentState.cs (1)
33/// different from the checksum acquired from <see cref="SourceText.GetChecksum"/>. Specifically, the original
Microsoft.CodeAnalysis.Workspaces.UnitTests (1)
SolutionTests\SolutionTests.cs (1)
1659Assert.Equal(expectedChecksum, document.GetTextSynchronously(default).GetChecksum());
Roslyn.VisualStudio.DiagnosticsWindow (1)
Panels\WorkspacePanel.xaml.cs (1)
96var fileChecksum = fileText.GetChecksum();