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