17 references to ThrowIfNull
Microsoft.CodeAnalysis.Workspaces (17)
Remote\RemoteArguments.cs (1)
63Contract.ThrowIfNull(project, WorkspacesResources.Symbols_project_could_not_be_found_in_the_provided_solution);
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\TestHooks\TaskExtensions.cs (2)
53Contract.ThrowIfNull(task, nameof(task)); 90Contract.ThrowIfNull(task, nameof(task));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\BKTree.cs (3)
53Contract.ThrowIfNull(concatenatedLowerCaseWords, nameof(_concatenatedLowerCaseWords)); 66Contract.ThrowIfNull(value, nameof(value)); 67Contract.ThrowIfNull(_concatenatedLowerCaseWords, nameof(_concatenatedLowerCaseWords));
src\Workspaces\SharedUtilitiesAndExtensions\Compiler\Core\Utilities\TaskExtensions.cs (6)
89Contract.ThrowIfNull(continuationAction, nameof(continuationAction)); 108Contract.ThrowIfNull(continuationFunction, nameof(continuationFunction)); 122Contract.ThrowIfNull(continuationAction, nameof(continuationAction)); 154Contract.ThrowIfNull(continuationFunction, nameof(continuationFunction)); 199Contract.ThrowIfNull(continuationFunction, nameof(continuationFunction)); 318Contract.ThrowIfNull(continuationFunction, nameof(continuationFunction));
TemporaryStorage\TemporaryStorageService.cs (2)
176Contract.ThrowIfNull(storageIdentifier.Name, $"{nameof(GetStreamHandle)} should only be called for VS on Windows (where named memory mapped files as supported)"); 187Contract.ThrowIfNull(storageIdentifier.Name, $"{nameof(GetTextHandle)} should only be called for VS on Windows (where named memory mapped files as supported)");
Workspace\ProjectSystem\ProjectSystemProject.BatchingDocumentCollection.cs (1)
481Contract.ThrowIfNull(fileInfo, "We previously received a dynamic file for this path, and we're responding to a change, so we expect to get a new one.");
Workspace\Solution\Solution.cs (1)
328Contract.ThrowIfNull(generatedDocument, "The call to GetDocumentState found a SourceGeneratedDocumentState, so we should have found it now.");
Workspace\Workspace_Editor.cs (1)
271Contract.ThrowIfNull(currentContextId, "The document is open, so we should have had some context ID.");