5 references to GetOrAdd
Microsoft.CodeAnalysis.Features (2)
EditAndContinue\AbstractEditAndContinueAnalyzer.cs (1)
2670=> symbolKeyCache.GetOrAdd(symbol, static (symbol, cancellationToken) => SymbolKey.Create(symbol, cancellationToken), cancellationToken);
Extensions\ExtensionMessageHandlerService.cs (1)
194lazyHandlers = cachedHandlers.GetOrAdd(
Microsoft.CodeAnalysis.Workspaces (3)
LinkedFileDiffMerging\LinkedFileDiffMergingSession.cs (1)
38var newDocumentsAndHashes = filePathToNewDocumentsAndHashes.GetOrAdd(filePath, static (_, capacity) => DocumentAndHashBuilder.GetInstance(capacity), relatedDocumentIds.Length);
Workspace\Solution\Project.cs (1)
269return idMap.GetOrAdd(documentId, tryCreate, arg);
Workspace\Solution\Solution.cs (1)
156return _projectIdToProjectMap.GetOrAdd(projectId, s_createProjectFunction, this);