9 references to ThrowIfNull
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 (4)
Handler\Diagnostics\AbstractPullDiagnosticHandler.cs (2)
344
Contract.
ThrowIfNull
(diagnostic.Tags, $"diagnostic {diagnostic.Identifier} was missing tags");
503
Contract.
ThrowIfNull
(diagnosticData.Language, $"diagnostic {diagnosticData.Id} is missing a language");
Handler\InlineCompletions\XmlSnippetParser.CodeSnippet.cs (1)
67
Contract.
ThrowIfNull
(snippets, $"Did not find any code snippets in {filePath}");
LspServices\LspServices.cs (1)
58
Contract.
ThrowIfNull
(service, $"Missing required LSP service {typeof(T).FullName}");
Microsoft.CodeAnalysis.Workspaces.UnitTests (2)
Options\OptionSerializerTests.cs (2)
90
Contract.
ThrowIfNull
(defaultValue, $"Option: {option.Name}");
111
Contract.
ThrowIfNull
(enumType, $"Option: {option.Name}");
Microsoft.VisualStudio.LanguageServices (1)
Implementation\AbstractEditorFactory.cs (1)
106
Contract.
ThrowIfNull
(textBuffer, $"Failed to get document data for {pszMkDocument}");