11 references to ThrowIfNull
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (3)
Options\OptionSerializerTests.cs (3)
79
Contract.
ThrowIfNull
(defaultValue, $"Option: {option.Name}");
101
Contract.
ThrowIfNull
(enumType, $"Option: {option.Name}");
132
Contract.
ThrowIfNull
(defaultValue, $"Option: {option.Name}");
Microsoft.CodeAnalysis.Features (2)
ReplacePropertyWithMethods\AbstractReplacePropertyWithMethodsService.cs (2)
124
Contract.
ThrowIfNull
(_expression.Parent, $"Parent of {_expression} is null.");
291
Contract.
ThrowIfNull
(_expression.Parent, $"Parent of {_expression} is null.");
Microsoft.CodeAnalysis.LanguageServer.Protocol (6)
Extensions\Extensions.cs (1)
64
Contract.
ThrowIfNull
(documentUri.ParsedUri, $"URI {documentUri} could not be parsed");
Extensions\ProtocolConversions.Diagnostics.cs (2)
59
Contract.
ThrowIfNull
(diagnosticData.Language, $"diagnostic {diagnosticData.Id} is missing a language");
69
Contract.
ThrowIfNull
(diagnostic.Tags, $"diagnostic {diagnostic.Identifier} was missing tags");
Extensions\SourceGeneratedDocumentUri.cs (1)
87
Contract.
ThrowIfNull
(value, $"Could not get {keyName} from {query}");
Handler\InlineCompletions\XmlSnippetParser.CodeSnippet.cs (1)
67
Contract.
ThrowIfNull
(snippets, $"Did not find any code snippets in {filePath}");
LspServices\LspServices.cs (1)
90
Contract.
ThrowIfNull
(service, $"Missing required LSP service {typeof(T).FullName}");