6288 references to ConfigureAwait
AnalyzerRunner (21)
DiagnosticAnalyzerRunner.cs (12)
69await GetAnalysisResultAsync(solution, _analyzers, _options, cancellationToken).ConfigureAwait(false);
86var analysisResult = await GetAnalysisResultAsync(solution, _analyzers, _options, cancellationToken).ConfigureAwait(false);
100_ = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
121var currentDocumentPerformance = await TestDocumentPerformanceAsync(_analyzers, project, documentId, _options, cancellationToken).ConfigureAwait(false);
185var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
192SyntaxTree tree = await project.GetDocument(documentId).GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
193await compilationWithAnalyzers.GetAnalyzerSyntaxDiagnosticsAsync(tree, cancellationToken).ConfigureAwait(false);
194await compilationWithAnalyzers.GetAnalyzerSemanticDiagnosticsAsync(compilation.GetSemanticModel(tree), null, cancellationToken).ConfigureAwait(false);
342await resultTask.ConfigureAwait(false);
350var result = await task.Value.ConfigureAwait(false);
393var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
397var analystResult = await compilationWithAnalyzers.GetAnalysisResultAsync(cancellationToken).ConfigureAwait(false);
aspire (20)
Interaction\ExtensionInteractionService.cs (8)
49var value = await task.ConfigureAwait(false);
74var result = await _backchannel.PromptForStringAsync(promptText.RemoveSpectreFormatting(), defaultValue, validator, required, _cancellationToken).ConfigureAwait(false);
83return await tcs.Task.ConfigureAwait(false);
87return await _consoleInteractionService.PromptForStringAsync(promptText, defaultValue, validator, isSecret, required, cancellationToken).ConfigureAwait(false);
101var result = await _backchannel.ConfirmAsync(promptText.RemoveSpectreFormatting(), defaultValue, _cancellationToken).ConfigureAwait(false);
111return await tcs.Task.ConfigureAwait(false);
130var result = await _backchannel.PromptForSelectionAsync(promptText.RemoveSpectreFormatting(), choices, choiceFormatter, _cancellationToken).ConfigureAwait(false);
140return await tcs.Task.ConfigureAwait(false);
Aspire.Azure.Messaging.WebPubSub (1)
Aspire.Azure.Search.Documents (1)
Aspire.Cli.Tests (1)
Aspire.Components.Common.TestUtilities (1)
Aspire.Confluent.Kafka (2)
Aspire.Dashboard (47)
Telemetry\DashboardTelemetryService.cs (14)
69await _telemetrySender.TryStartTelemetrySessionAsync().ConfigureAwait(false);
115var response = await PostRequestAsync<StartOperationRequest, StartOperationResponse>(client, TelemetryEndpoints.TelemetryStartOperation, new StartOperationRequest(eventName, scopeSettings)).ConfigureAwait(false);
136await client.PostAsJsonAsync(TelemetryEndpoints.TelemetryEndOperation, new EndOperationRequest(Id: (string)propertyGetter(operationId), Result: result, ErrorMessage: errorMessage)).ConfigureAwait(false);
161var response = await PostRequestAsync<StartOperationRequest, StartOperationResponse>(client, TelemetryEndpoints.TelemetryStartUserTask, new StartOperationRequest(eventName, scopeSettings)).ConfigureAwait(false);
182await client.PostAsJsonAsync(TelemetryEndpoints.TelemetryEndUserTask, new EndOperationRequest(Id: (string)propertyGetter(operationId), Result: result, ErrorMessage: errorMessage)).ConfigureAwait(false);
208var response = await PostRequestAsync<PostOperationRequest, TelemetryEventCorrelation>(client, TelemetryEndpoints.TelemetryPostOperation, request).ConfigureAwait(false);
236var response = await PostRequestAsync<PostOperationRequest, TelemetryEventCorrelation>(client, TelemetryEndpoints.TelemetryPostUserTask, request).ConfigureAwait(false);
264var response = await PostRequestAsync<PostFaultRequest, TelemetryEventCorrelation>(client, TelemetryEndpoints.TelemetryPostFault, request).ConfigureAwait(false);
293var response = await PostRequestAsync<PostAssetRequest, TelemetryEventCorrelation>(client, TelemetryEndpoints.TelemetryPostAsset, request).ConfigureAwait(false);
314await client.PostAsJsonAsync(TelemetryEndpoints.TelemetryPostProperty, request).ConfigureAwait(false);
332await client.PostAsJsonAsync(TelemetryEndpoints.TelemetryPostRecurringProperty, request).ConfigureAwait(false);
350await client.PostAsJsonAsync(TelemetryEndpoints.TelemetryPostCommandLineFlags, request).ConfigureAwait(false);
356var httpResponseMessage = await client.PostAsJsonAsync(endpoint, request).ConfigureAwait(false);
358var response = await httpResponseMessage.Content.ReadFromJsonAsync<TResponse>().ConfigureAwait(false);
Aspire.Dashboard.Components.Tests (2)
Aspire.Dashboard.Tests (3)
Aspire.EndToEnd.Tests (6)
Aspire.Hosting (133)
ApplicationModel\ExpressionResolver.cs (9)
72await EvalEndpointAsync(endpointReference, EndpointProperty.Host).ConfigureAwait(false),
73await EvalEndpointAsync(endpointReference, EndpointProperty.Port).ConfigureAwait(false)),
75await EvalEndpointAsync(endpointReference, EndpointProperty.Host).ConfigureAwait(false),
76await EvalEndpointAsync(endpointReference, EndpointProperty.Port).ConfigureAwait(false)),
178ConnectionStringReference cs => await ResolveConnectionStringReferenceAsync(cs).ConfigureAwait(false),
180ReferenceExpression ex => await EvalExpressionAsync(ex).ConfigureAwait(false),
181EndpointReference endpointReference when sourceIsContainer => new ResolvedValue(await EvalEndpointAsync(endpointReference, EndpointProperty.Url).ConfigureAwait(false), false),
182EndpointReferenceExpression ep when sourceIsContainer => new ResolvedValue(await EvalEndpointAsync(ep.Endpoint, ep.Property).ConfigureAwait(false), false),
183IValueProvider vp => await EvalValueProvider(vp).ConfigureAwait(false),
ApplicationModel\InteractionService.cs (8)
41return await PromptMessageBoxCoreAsync(title, message, options, cancellationToken).ConfigureAwait(false);
50return await PromptMessageBoxCoreAsync(title, message, options, cancellationToken).ConfigureAwait(false);
67var completion = await newState.CompletionTcs.Task.ConfigureAwait(false);
76return await PromptInputAsync(title, message, new InteractionInput { InputType = InputType.Text, Label = inputLabel, Required = true, Placeholder = placeHolder }, options, cancellationToken).ConfigureAwait(false);
81var result = await PromptInputsAsync(title, message, [input], options, cancellationToken).ConfigureAwait(false);
103var completion = await newState.CompletionTcs.Task.ConfigureAwait(false);
123var completion = await newState.CompletionTcs.Task.ConfigureAwait(false);
198if (!await RunValidationAsync(interactionState, result, cancellationToken).ConfigureAwait(false))
ApplicationModel\ResourceExtensions.cs (5)
303(DistributedApplicationOperation.Run, IValueProvider provider) => await GetValue(key: null, provider, logger, resource.IsContainer(), containerHostName, cancellationToken).ConfigureAwait(false),
304(DistributedApplicationOperation.Run, IResourceBuilder<IResource> rb) when rb.Resource is IValueProvider provider => await GetValue(key: null, provider, logger, resource.IsContainer(), containerHostName, cancellationToken).ConfigureAwait(false),
362(DistributedApplicationOperation.Run, IValueProvider provider) => await GetValue(key, provider, logger, resource.IsContainer(), containerHostName, cancellationToken).ConfigureAwait(false),
363(DistributedApplicationOperation.Run, IResourceBuilder<IResource> rb) when rb.Resource is IValueProvider provider => await GetValue(key, provider, logger, resource.IsContainer(), containerHostName, cancellationToken).ConfigureAwait(false),
416IValueProvider valueProvider => (await GetValue(key: null, valueProvider, logger, resource.IsContainer(), containerHostName, cancellationToken).ConfigureAwait(false))?.Value,
ApplicationModel\ResourceNotificationService.cs (7)
162var resourceEvent = await WaitForResourceCoreAsync(dependency.Name, re => re.ResourceId == resourceId && IsContinuableState(waitBehavior, re.Snapshot), cancellationToken: cancellationToken).ConfigureAwait(false);
197await WaitForResourceCoreAsync(dependency.Name, re => re.ResourceId == resourceId && re.Snapshot.HealthStatus == HealthStatus.Healthy, cancellationToken).ConfigureAwait(false);
202resourceEvent = await WaitForResourceCoreAsync(dependency.Name, re => re.ResourceId == resourceId && re.Snapshot.ResourceReadyEvent is not null, cancellationToken: cancellationToken).ConfigureAwait(false);
247cancellationToken).ConfigureAwait(false);
278var resourceEvent = await WaitForResourceCoreAsync(resourceName, re => ShouldYield(waitBehavior, re.Snapshot), cancellationToken: cancellationToken).ConfigureAwait(false);
324var resourceEvent = await WaitForResourceCoreAsync(dependency.Name, re => re.ResourceId == resourceId && IsKnownTerminalState(re.Snapshot), cancellationToken: cancellationToken).ConfigureAwait(false);
411var resourceEvent = await WaitForResourceCoreAsync(resourceName, predicate, cancellationToken).ConfigureAwait(false);
Dcp\DcpExecutor.cs (19)
117_dcpInfo = await _dcpDependencyCheckService.GetDcpInfoAsync(cancellationToken: cancellationToken).ConfigureAwait(false);
686var dcpSvc = await _kubernetesService.GetAsync<Service>(sar.Service.Metadata.Name, cancellationToken: cancellationToken).ConfigureAwait(false);
711await _kubernetesService.CreateAsync(cn, cancellationToken).ConfigureAwait(false);
1060(var appHostArgs, var failedToApplyArgs) = await BuildArgsAsync(resourceLogger, er.ModelResource, cancellationToken).ConfigureAwait(false);
1074(spec.Env, var failedToApplyConfiguration) = await BuildEnvVarsAsync(resourceLogger, er.ModelResource, cancellationToken).ConfigureAwait(false);
1081await _kubernetesService.CreateAsync(exe, cancellationToken).ConfigureAwait(false);
1298spec.CreateFiles = await BuildCreateFilesAsync(modelContainerResource, cancellationToken).ConfigureAwait(false);
1300(spec.RunArgs, var failedToApplyRunArgs) = await BuildRunArgsAsync(resourceLogger, modelContainerResource, cancellationToken).ConfigureAwait(false);
1302(var args, var failedToApplyArgs) = await BuildArgsAsync(resourceLogger, modelContainerResource, cancellationToken).ConfigureAwait(false);
1306(spec.Env, var failedToApplyConfiguration) = await BuildEnvVarsAsync(resourceLogger, modelContainerResource, cancellationToken).ConfigureAwait(false);
1323await _kubernetesService.CreateAsync(dcpContainerResource, cancellationToken).ConfigureAwait(false);
1538await _kubernetesService.CreateAsync(res, cancellationToken).ConfigureAwait(false);
1581await _kubernetesService.PatchAsync(c, patch, attemptCancellationToken).ConfigureAwait(false);
1582var cu = await _kubernetesService.GetAsync<Container>(c.Metadata.Name, cancellationToken: attemptCancellationToken).ConfigureAwait(false);
1596await _kubernetesService.PatchAsync(e, patch, attemptCancellationToken).ConfigureAwait(false);
1597var eu = await _kubernetesService.GetAsync<Executable>(e.Metadata.Name, cancellationToken: attemptCancellationToken).ConfigureAwait(false);
1693var r = await _kubernetesService.DeleteAsync<T>(resourceName, cancellationToken: attemptCancellationToken).ConfigureAwait(false);
1714var r = await _kubernetesService.GetAsync<T>(resourceName, cancellationToken: attemptCancellationToken).ConfigureAwait(false);
1777cancellationToken).ConfigureAwait(false);
Dcp\ResourceLogSource.cs (4)
37var startupStderrStream = await kubernetesService.GetLogStreamAsync(resource, Logs.StreamTypeStartupStdErr, cancellationToken, follow: follow, timestamps: true).ConfigureAwait(false);
38var startupStdoutStream = await kubernetesService.GetLogStreamAsync(resource, Logs.StreamTypeStartupStdOut, cancellationToken, follow: follow, timestamps: true).ConfigureAwait(false);
46var stdoutStream = await kubernetesService.GetLogStreamAsync(resource, Logs.StreamTypeStdOut, cancellationToken, follow: follow, timestamps: true).ConfigureAwait(false);
47var stderrStream = await kubernetesService.GetLogStreamAsync(resource, Logs.StreamTypeStdErr, cancellationToken, follow: follow, timestamps: true).ConfigureAwait(false);
Aspire.Hosting.Azure (28)
Aspire.Hosting.Azure.AIFoundry (2)
Aspire.Hosting.Azure.AppContainers (1)
Aspire.Hosting.Azure.AppService (1)
Aspire.Hosting.Azure.CosmosDB (3)
Aspire.Hosting.Azure.KeyVault (1)
Aspire.Hosting.Azure.Storage (1)
Aspire.Hosting.Docker (7)
Aspire.Hosting.Kafka.Tests (2)
Aspire.Hosting.Kubernetes (7)
Aspire.Hosting.MySql (2)
Aspire.Hosting.MySql.Tests (2)
Aspire.Hosting.Nats (1)
Aspire.Hosting.NodeJs.Tests (2)
Aspire.Hosting.PostgreSQL (1)
Aspire.Hosting.PostgreSQL.Tests (2)
Aspire.Hosting.Qdrant (1)
Aspire.Hosting.RabbitMQ (1)
Aspire.Hosting.RabbitMQ.Tests (2)
Aspire.Hosting.SqlServer (3)
Aspire.Hosting.Testing (9)
Aspire.Hosting.Tests (3)
Aspire.Hosting.Valkey.Tests (2)
Aspire.Hosting.Yarp (1)
Aspire.Milvus.Client (1)
Aspire.NATS.Net (1)
Aspire.Playground.Tests (2)
Aspire.Qdrant.Client (1)
Aspire.RabbitMQ.Client (1)
Aspire.Seq (1)
Aspire.Templates.Tests (8)
Binding.Tcp.IntegrationTests (1)
ConfigurationSchemaGenerator (1)
csc (7)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
dotnet-openapi (1)
dotnet-svcutil-lib (243)
Bootstrapper\SvcutilBootstrapper.cs (9)
62using (await SafeLogger.WriteStartOperationAsync(logger, "Bootstrapping svcutil ...").ConfigureAwait(false))
83var paramsFilePath = await GenerateParamsFileAsync(logger, cancellationToken).ConfigureAwait(false);
88result = await ProcessRunner.RunAsync("dotnet", $"run \"{paramsFilePath}\"", this.MSBuildProj.DirectoryPath, redirectOutput, logger, cancellationToken).ConfigureAwait(false);
115using (await SafeLogger.WriteStartOperationAsync(logger, $"Creating project file: \"{projectFullPath}\"").ConfigureAwait(false))
123this.MSBuildProj = await MSBuildProj.DotNetNewAsync(projectFullPath, logger, cancellationToken).ConfigureAwait(false);
168using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Generating Program.cs ...").ConfigureAwait(false))
178using (await SafeLogger.WriteStartOperationAsync(logger, $"Generating {paramsFilePath} params file ...").ConfigureAwait(false))
193var restoreResult = await this.MSBuildProj.RestoreAsync(logger, cancellationToken).ConfigureAwait(false);
201var buildResult = await this.MSBuildProj.BuildAsync(logger, cancellationToken).ConfigureAwait(false);
CommandProcessorOptions.cs (14)
289using (SafeLogger safeLogger = await SafeLogger.WriteStartOperationAsync(this.Logger, "Validating options ...").ConfigureAwait(false))
332using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Resolving {ProjectFileKey} option ...").ConfigureAwait(false))
372this.Project = await MSBuildProj.FromPathAsync(projectFile, this.Logger, cancellationToken).ConfigureAwait(false);
380using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Resolving {OutputDirKey} option ...").ConfigureAwait(false))
417using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Resolving {OutputFileKey} option ...").ConfigureAwait(false))
467using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Processing {UpdateServiceReferenceKey} option ...").ConfigureAwait(false))
570using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Processing {BootstrapPathKey} option ...").ConfigureAwait(false))
617using (var logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Processing {nameof(this.References)}, count: {this.References.Count}. Reference resolution enabled: {resolveReferences}").ConfigureAwait(false))
621var references = await this.Project.ResolveProjectReferencesAsync(ProjectDependency.IgnorableDependencies, logger, cancellationToken).ConfigureAwait(false);
646using (var logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Processing {nameof(this.NamespaceMappings)}, count: {this.NamespaceMappings.Count}").ConfigureAwait(false))
696using (SafeLogger logger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Resolving {TargetFrameworkKey} option ...").ConfigureAwait(false))
709using (var proj = await MSBuildProj.DotNetNewAsync(projectFullPath, this.Logger, cancellationToken).ConfigureAwait(false))
729using (var safeLogger = await SafeLogger.WriteStartOperationAsync(this.Logger, $"Processing inputs, count: {this.Inputs.Count} ...").ConfigureAwait(false))
804using (var logger = await SafeLogger.WriteStartOperationAsync(this.Logger, "Processing reference assemblies ...").ConfigureAwait(false))
FrameworkFork\Microsoft.Xml\Xml\Core\ReadContentAsBinaryHelperAsync.cs (24)
44if (!await InitAsync().ConfigureAwait(false))
54return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
70return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
100if (!await InitAsync().ConfigureAwait(false))
110return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
126return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
156if (!await InitOnElementAsync().ConfigureAwait(false))
168return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
182return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
212if (!await InitOnElementAsync().ConfigureAwait(false))
224return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
238return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
245while (await MoveToNextContentNodeAsync(true).ConfigureAwait(false))
254await _reader.ReadAsync().ConfigureAwait(false);
264if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
280await _reader.ReadAsync().ConfigureAwait(false);
287if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
294await _reader.ReadAsync().ConfigureAwait(false);
330if ((_valueChunkLength = await _reader.ReadValueChunkAsync(_valueChunk, 0, ChunkSize).ConfigureAwait(false)) == 0)
340string value = await _reader.GetValueAsync().ConfigureAwait(false);
353if (!await MoveToNextContentNodeAsync(true).ConfigureAwait(false))
368int decoded = await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
381await _reader.ReadAsync().ConfigureAwait(false);
419} while (await _reader.ReadAsync().ConfigureAwait(false));
FrameworkFork\Microsoft.Xml\Xml\Core\XmlCharCheckingReaderAsync.cs (24)
44if (!await base.reader.ReadAsync().ConfigureAwait(false))
64return await ReadAsync().ConfigureAwait(false);
70return await ReadAsync().ConfigureAwait(false);
76return await ReadAsync().ConfigureAwait(false);
86return await ReadAsync().ConfigureAwait(false);
120CheckCharacters(await base.reader.GetValueAsync().ConfigureAwait(false));
135return await ReadAsync().ConfigureAwait(false);
147return await ReadAsync().ConfigureAwait(false);
162return await ReadAsync().ConfigureAwait(false);
191return await ReadAsync().ConfigureAwait(false);
195CheckWhitespace(await base.reader.GetValueAsync().ConfigureAwait(false));
202CheckWhitespace(await base.reader.GetValueAsync().ConfigureAwait(false));
236return await base.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
249return await base.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
257int readCount = await _readBinaryHelper.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
279return await base.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
292return await base.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
300int readCount = await _readBinaryHelper.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
340return await base.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
353return await base.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
361int readCount = await _readBinaryHelper.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
400return await base.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
413return await base.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
421int readCount = await _readBinaryHelper.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
FrameworkFork\Microsoft.Xml\Xml\Core\XmlSubtreeReaderAsync.cs (29)
59if (await reader.ReadAsync().ConfigureAwait(false))
86if (!await FinishReadElementContentAsBinaryAsync().ConfigureAwait(false))
90return await ReadAsync().ConfigureAwait(false);
94if (!await FinishReadContentAsBinaryAsync().ConfigureAwait(false))
98return await ReadAsync().ConfigureAwait(false);
111await ReadAsync().ConfigureAwait(false);
124if (await reader.ReadAsync().ConfigureAwait(false))
165if (await FinishReadElementContentAsBinaryAsync().ConfigureAwait(false))
173if (await FinishReadContentAsBinaryAsync().ConfigureAwait(false))
193object value = await reader.ReadContentAsObjectAsync().ConfigureAwait(false);
209string value = await reader.ReadContentAsStringAsync().ConfigureAwait(false);
225object value = await reader.ReadContentAsAsync(returnType, namespaceResolver).ConfigureAwait(false);
285return await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
296int read = await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
328if (!await InitReadElementContentAsBinaryAsync(State.ReadElementContentAsBase64).ConfigureAwait(false))
335int read = await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
357await ReadAsync().ConfigureAwait(false);
421return await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
432int read = await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
464if (!await InitReadElementContentAsBinaryAsync(State.ReadElementContentAsBinHex).ConfigureAwait(false))
470int read = await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
492await ReadAsync().ConfigureAwait(false);
568if (!await ReadAsync().ConfigureAwait(false) || isEmpty)
580await ReadAsync().ConfigureAwait(false);
596while (await reader.ReadContentAsBase64Async(bytes, 0, 256).ConfigureAwait(false) > 0) ;
600while (await reader.ReadContentAsBinHexAsync(bytes, 0, 256).ConfigureAwait(false) > 0) ;
620return await ReadAsync().ConfigureAwait(false);
630while (await reader.ReadContentAsBase64Async(bytes, 0, 256).ConfigureAwait(false) > 0) ;
634while (await reader.ReadContentAsBinHexAsync(bytes, 0, 256).ConfigureAwait(false) > 0) ;
FrameworkFork\Microsoft.Xml\Xml\Core\XsdValidatingReaderAsync.cs (21)
51object typedValue = await InternalReadContentAsObjectAsync().ConfigureAwait(false);
86var tuple_0 = await InternalReadContentAsObjectTupleAsync(false).ConfigureAwait(false);
130var tuple_1 = await InternalReadElementContentAsObjectAsync(true).ConfigureAwait(false);
143var tuple_9 = await InternalReadElementContentAsObjectAsync().ConfigureAwait(false);
182var tuple_10 = await InternalReadElementContentAsObjectTupleAsync(false).ConfigureAwait(false);
245if (await task.ConfigureAwait(false))
369await ReadAsync().ConfigureAwait(false);
391int readCount = await _readBinaryHelper.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
417int readCount = await _readBinaryHelper.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
443int readCount = await _readBinaryHelper.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
469int readCount = await _readBinaryHelper.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
628if (await _coreReader.ReadAsync().ConfigureAwait(false))
656var tuple_11 = await InternalReadContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
708object value = ReturnBoxedValue(await ReadTillEndElementAsync().ConfigureAwait(false), _xmlSchemaInfo.XmlType, unwrapTypedValue);
723originalStringValue = await InternalReadContentAsStringAsync().ConfigureAwait(false);
739var tuple_13 = await InternalReadElementContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
766await this.ReadAsync().ConfigureAwait(false);
772await this.ReadAsync().ConfigureAwait(false);
800var tuple_14 = await InternalReadContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
814await this.ReadAsync().ConfigureAwait(false);
824while (await _coreReader.ReadAsync().ConfigureAwait(false))
Metadata\MetadaExchangeResolver.cs (10)
104metadataResolved = await ResolveMetadataAsync(this.EndpointAddress.Uri, MetadataExchangeClientMode.HttpGet, true, cancellationToken).ConfigureAwait(false);
109metadataResolved = await ResolveMetadataAsync(new Uri(baseUri + mexUri), MetadataExchangeClientMode.MetadataExchange, false, cancellationToken).ConfigureAwait(false);
114metadataResolved = await ResolveMetadataAsync(this.EndpointAddress.Uri, MetadataExchangeClientMode.MetadataExchange, true, cancellationToken).ConfigureAwait(false);
118metadataResolved = await ResolveMetadataAsync(new Uri(baseUri + wsdlQuery), MetadataExchangeClientMode.HttpGet, false, cancellationToken).ConfigureAwait(false);
127using (var stream = await DownloadMetadataFileAsync(cancellationToken).ConfigureAwait(false))
129metadataResolved = await ResolveMetadataAsync(stream, baseUri, cancellationToken).ConfigureAwait(false);
134metadataResolved = await ResolveMetadataAsync(new Uri(baseUri + wsdlQuery), MetadataExchangeClientMode.HttpGet, false, cancellationToken).ConfigureAwait(false);
138metadataResolved = await ResolveMetadataAsync(new Uri(baseUri), MetadataExchangeClientMode.HttpGet, true, cancellationToken).ConfigureAwait(false);
146metadataResolved = await ResolveMetadataAsync(new Uri(baseUri), MetadataExchangeClientMode.MetadataExchange, false, cancellationToken).ConfigureAwait(false);
149metadataResolved = await ResolveMetadataAsync(new Uri(baseUri + mexUri), MetadataExchangeClientMode.MetadataExchange, false, cancellationToken).ConfigureAwait(false);
Metadata\MetadataDocumentLoader.cs (9)
239var metadataSections = await metadataExchangeResolver.ResolveMetadataAsync(cancellationToken).ConfigureAwait(false);
319var schema = await AsyncHelper.RunAsync(() => XmlNS.Schema.XmlSchema.Read(reader, null), cancellationToken).ConfigureAwait(false);
338var resolvedLocation = await LoadAsSchemaImportLocationAsync(externalSchema.SchemaLocation, uri, basePath, schemaNamespace, ".xsd", cancellationToken).ConfigureAwait(false);
346WsdlNS.ServiceDescription wsdl = await AsyncHelper.RunAsync(() => WsdlNS.ServiceDescription.Read(reader), cancellationToken).ConfigureAwait(false);
356var resolvedLocation = await LoadAsSchemaImportLocationAsync(import.Location, uri, basePath, import.Namespace, ".wsdl", cancellationToken).ConfigureAwait(false);
387using (var stream = await DownloadSchemaImportAsync(schemaUri, cancellationToken).ConfigureAwait(false))
431EndpointAddress epr = await AsyncHelper.RunAsync(() => EndpointAddress.ReadFrom(dictionaryReader), cancellationToken).ConfigureAwait(false);
434IEnumerable<MetadataSection> resolvedMetadata = await resolver.ResolveMetadataAsync(cancellationToken).ConfigureAwait(false);
571return await metadataExchangeResolver.DownloadMetadataFileAsync(cancellationToken).ConfigureAwait(false);
Shared\MSBuildProj.cs (26)
147var project = await ParseAsync(File.ReadAllText(filePath), filePath, logger, cancellationToken).ConfigureAwait(false);
154var project = await ParseAsync(File.ReadAllText(filePath), filePath, logger, cancellationToken, tfMoniker).ConfigureAwait(false);
161using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Parsing project {Path.GetFileName(projectFullPath)}").ConfigureAwait(false))
361var sdkVersion = await ProjectPropertyResolver.GetSdkVersionAsync(msbuildProj.DirectoryPath, logger, cancellationToken).ConfigureAwait(false);
408var sdkVersion = await ProjectPropertyResolver.GetSdkVersionAsync(projectDir, logger, cancellationToken).ConfigureAwait(false);
410await ProcessRunner.RunAsync("dotnet", dotnetNewParams, projectDir, logger, cancellationToken).ConfigureAwait(false);
412project = await ParseAsync(File.ReadAllText(fullPath), fullPath, logger, cancellationToken).ConfigureAwait(false);
693using (await SafeLogger.WriteStartOperationAsync(logger, $"Saving project file: \"{this.FullPath}\"").ConfigureAwait(false))
722await ProcessRunner.TryRunAsync("dotnet", restoreParams + " --no-dependencies", this.DirectoryPath, logger, cancellationToken).ConfigureAwait(false);
723var result = await ProcessRunner.TryRunAsync("dotnet", restoreParams, this.DirectoryPath, logger, cancellationToken).ConfigureAwait(false);
735await this.RestoreAsync(logger, cancellationToken).ConfigureAwait(false);
737return await BuildAsync(logger, cancellationToken).ConfigureAwait(false);
745return await ProcessRunner.RunAsync("dotnet", buildParams, this.DirectoryPath, logger, cancellationToken).ConfigureAwait(false);
761using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Resolving project references ...").ConfigureAwait(false))
765await this.RestoreAsync(logger, cancellationToken).ConfigureAwait(false);
767var packageReferences = await ResolvePackageReferencesAsync(logger, cancellationToken).ConfigureAwait(false);
768var assemblyReferences = await ResolveAssemblyReferencesAsync(logger, cancellationToken).ConfigureAwait(false);
791using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Resolving package references ...").ConfigureAwait(false))
853}, cancellationToken).ConfigureAwait(false);
869using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Resolving assembly references for {this.TargetFramework} target framework ...").ConfigureAwait(false))
871await ResolveProperyValuesAsync(new string[] { "OutputPath", "TargetPath" }, logger, cancellationToken).ConfigureAwait(false);
881await ResolveDepsFilePathFromBuildConfigAsync(outputPath, logger, cancellationToken).ConfigureAwait(false);
934}, cancellationToken).ConfigureAwait(false);
976propertyTable = await _propertyResolver.EvaluateProjectPropertiesAsync(this.FullPath, this.TargetFramework, propertyNames, this.GlobalProperties, logger, cancellationToken).ConfigureAwait(false);
994using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Resolving deps.json file ...").ConfigureAwait(false))
1000var binFolder = await PathHelper.TryFindFolderAsync("bin", outputPath, logger, cancellationToken).ConfigureAwait(false);
Shared\ProjectPropertyResolver.cs (9)
27using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Resolving {propertyNames.Count()} project properties ...").ConfigureAwait(false))
33var sdkVersion = await GetSdkVersionAsync(workingDirectory, logger, cancellationToken).ConfigureAwait(false);
34var sdkPath = await GetSdkPathAsync(workingDirectory, logger, cancellationToken).ConfigureAwait(false);
49Assembly msbuildAssembly = await LoadMSBuildAssembliesAsync(sdkPath, logger, cancellationToken).ConfigureAwait(false);
121using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Resolving dotnet sdk version ...").ConfigureAwait(false))
123var procResult = await ProcessRunner.TryRunAsync("dotnet", "--version", workingDirectory, logger, cancellationToken).ConfigureAwait(false);
141using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Resolving .NETCore SDK path ...").ConfigureAwait(false))
156var sdkVersion = await GetSdkVersionAsync(workingDirectory, logger, cancellationToken).ConfigureAwait(false);
176using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, "Loading MSBuild assemblies ...").ConfigureAwait(false))
Shared\Utilities\PathHelper.cs (5)
207var filePath = await TryFindFileAsync(fileName, workingDirectory, logger, cancellationToken).ConfigureAwait(false);
211using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Copying {fileName} to {destinationDir} ...").ConfigureAwait(false))
230return await TryFindItemAsync(Directory.EnumerateFiles, fileName, workingDir, logger, cancellationToken).ConfigureAwait(false);
235return await TryFindItemAsync(Directory.EnumerateDirectories, folderName, workingDir, logger, cancellationToken).ConfigureAwait(false);
243using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Looking for '{itemName}' up from '{workingDir}' dir ...").ConfigureAwait(false))
Shared\Utilities\ProcessRunner.cs (5)
35return await RunAsync(processName, processArgs, currentDir, redirectOutput: true, throwOnError: true, logger: logger, cancellationToken: cancellationToken).ConfigureAwait(false);
40return await RunAsync(processName, processArgs, currentDir, redirectOutput: redirectOutput, throwOnError: true, logger: logger, cancellationToken: cancellationToken).ConfigureAwait(false);
45return await RunAsync(processName, processArgs, currentDir, redirectOutput: true, throwOnError: false, logger: logger, cancellationToken: cancellationToken).ConfigureAwait(false);
50return await RunAsync(processName, processArgs, currentDir, redirectOutput, throwOnError, emptyVars, logger, cancellationToken).ConfigureAwait(false);
66using (var safeLogger = await SafeLogger.WriteStartOperationAsync(logger, $"Executing command [\"{currentDir}\"]{Environment.NewLine}>{processName} {processArgs}").ConfigureAwait(false))
dotnet-svcutil-lib.Tests (1)
GenerateDocumentationAndConfigFiles (69)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
GenerateRulesMissingDocumentation (2)
IdeBenchmarks (2)
IdentitySample.PasskeyConformance (1)
IIS.Common.TestLib (2)
ILLink.CodeFixProvider (6)
InMemory.FunctionalTests (9)
InteropClient (2)
InteropWebsite (1)
Metrics (36)
Program.cs (8)
62(ImmutableArray<(string, CodeAnalysisMetricData)> metricDatas, ErrorCode exitCode) = await GetMetricDatasAsync(projectsOrSolutions, quiet, cancellationToken).ConfigureAwait(false);
69errorCode = await writeOutputAsync().ConfigureAwait(false);
305var project = await workspace.OpenProjectAsync(projectFile, cancellationToken: CancellationToken.None).ConfigureAwait(false);
318var compilation = await project.GetCompilationAsync(CancellationToken.None).ConfigureAwait(false);
319var metricData = await CodeAnalysisMetricData.ComputeAsync(compilation!.Assembly, new CodeMetricsAnalysisContext(compilation, CancellationToken.None)).ConfigureAwait(false);
331var solution = await workspace.OpenSolutionAsync(solutionFile, cancellationToken: CancellationToken.None).ConfigureAwait(false);
351var compilation = await project.GetCompilationAsync(CancellationToken.None).ConfigureAwait(false);
352var metricData = await CodeAnalysisMetricData.ComputeAsync(compilation!.Assembly, new CodeMetricsAnalysisContext(compilation, CancellationToken.None)).ConfigureAwait(false);
Metrics.Legacy (36)
src\RoslynAnalyzers\Tools\Metrics\Program.cs (8)
62(ImmutableArray<(string, CodeAnalysisMetricData)> metricDatas, ErrorCode exitCode) = await GetMetricDatasAsync(projectsOrSolutions, quiet, cancellationToken).ConfigureAwait(false);
69errorCode = await writeOutputAsync().ConfigureAwait(false);
305var project = await workspace.OpenProjectAsync(projectFile, cancellationToken: CancellationToken.None).ConfigureAwait(false);
318var compilation = await project.GetCompilationAsync(CancellationToken.None).ConfigureAwait(false);
319var metricData = await CodeAnalysisMetricData.ComputeAsync(compilation!.Assembly, new CodeMetricsAnalysisContext(compilation, CancellationToken.None)).ConfigureAwait(false);
331var solution = await workspace.OpenSolutionAsync(solutionFile, cancellationToken: CancellationToken.None).ConfigureAwait(false);
351var compilation = await project.GetCompilationAsync(CancellationToken.None).ConfigureAwait(false);
352var metricData = await CodeAnalysisMetricData.ComputeAsync(compilation!.Assembly, new CodeMetricsAnalysisContext(compilation, CancellationToken.None)).ConfigureAwait(false);
Microsoft.Analyzers.Extra (18)
Microsoft.Analyzers.Extra.Tests (25)
Microsoft.Analyzers.Local.Tests (24)
Microsoft.AspNetCore.Analyzers (1)
Microsoft.AspNetCore.App.Analyzers (4)
Microsoft.AspNetCore.App.Analyzers.Test (3)
Microsoft.AspNetCore.App.CodeFixes (15)
Microsoft.AspNetCore.Authorization (11)
Microsoft.AspNetCore.Components (1)
Microsoft.AspNetCore.Components.Analyzers (1)
Microsoft.AspNetCore.Components.SdkAnalyzers (1)
Microsoft.AspNetCore.Components.WebView.Maui (2)
Microsoft.AspNetCore.Components.WebView.WindowsForms (2)
Microsoft.AspNetCore.Components.WebView.Wpf (2)
Microsoft.AspNetCore.Diagnostics.Middleware.Tests (26)
Microsoft.AspNetCore.Http.Connections.Client (21)
Microsoft.AspNetCore.Identity (11)
Microsoft.AspNetCore.Identity.EntityFrameworkCore (12)
Microsoft.AspNetCore.InternalTesting (26)
Microsoft.AspNetCore.Mvc.Api.Analyzers (8)
Microsoft.AspNetCore.OutputCaching.StackExchangeRedis (15)
RedisOutputCacheStore.cs (15)
133if (!await cache.StringSetAsync(gcKey, DateTime.UtcNow.ToString(CultureInfo.InvariantCulture), gcLifetime, when: When.NotExists).ConfigureAwait(false))
149await cache.SortedSetRemoveRangeByScoreAsync(GetTagKey((string)entry.Element!), start: 0, stop: keepValuesGreaterThan, flags: GarbageCollectionFlags).ConfigureAwait(false);
152await cache.KeyExpireAsync(gcKey, gcLifetime).ConfigureAwait(false);
157return await cache.SortedSetRemoveRangeByScoreAsync(_tagMasterKey, start: 0, stop: keepValuesGreaterThan).ConfigureAwait(false);
161await cache.KeyDeleteAsync(gcKey, CommandFlags.FireAndForget).ConfigureAwait(false);
177await cache.KeyDeleteAsync(GetValueKey((string)entry.Element!), DeleteFlags).ConfigureAwait(false);
178await cache.SortedSetRemoveAsync(tagKey, entry.Element, DeleteFlags).ConfigureAwait(false);
197return (byte[]?)(await cache.StringGetAsync(GetValueKey(key)).ConfigureAwait(false));
217result = await cache.StringGetLeaseAsync(GetValueKey(key)).ConfigureAwait(false);
262await cache.StringSetAsync(GetValueKey(key), singleChunk, validFor).ConfigureAwait(false);
283await cache.SortedSetAddAsync(_tagMasterKey, tag, expiryTimestamp, SortedSetWhen.GreaterThan, TagCommandFlags).ConfigureAwait(false);
297await cache.ScriptEvaluateAsync(ZADD_GT, _tagMasterKeyArray, new RedisValue[] { expiryTimestamp, tag }, TagCommandFlags).ConfigureAwait(false);
299await cache.SortedSetAddAsync(GetTagKey(tag), key, expiryTimestamp, SortedSetWhen.Always, TagCommandFlags).ConfigureAwait(false);
335connection = await ConnectionMultiplexer.ConnectAsync(_options.GetConfiguredOptions()).ConfigureAwait(false);
339connection = await _options.ConnectionMultiplexerFactory().ConfigureAwait(false);
Microsoft.AspNetCore.Server.IntegrationTesting (1)
Microsoft.AspNetCore.Server.Kestrel.Core (6)
Microsoft.AspNetCore.Server.Kestrel.Core.Tests (2)
Microsoft.AspNetCore.SignalR.Client.Core (15)
HubConnection.cs (11)
438return await StreamAsChannelCoreAsyncCore(methodName, returnType, args, cancellationToken).ConfigureAwait(false);
460return await InvokeCoreAsyncCore(methodName, returnType, args, cancellationToken).ConfigureAwait(false);
682var reader = await StreamAsChannelCoreAsync(methodName, typeof(T), args, cts.Token).ConfigureAwait(false);
738var (connectionState, activity) = await WaitForActiveConnectionWithActivityAsync(nameof(StreamAsChannelCoreAsync), methodName, token: cancellationToken).ConfigureAwait(false);
1045connectionState = await connectionStateTask.ConfigureAwait(false);
1085var (connectionState, activity) = await WaitForActiveConnectionWithActivityAsync(nameof(InvokeCoreAsync), methodName, token: cancellationToken).ConfigureAwait(false);
1105return await invocationTask.ConfigureAwait(false);
1235var (connectionState, activity) = await WaitForActiveConnectionWithActivityAsync(nameof(SendCoreAsync), methodName, token: cancellationToken).ConfigureAwait(false);
1272var connectionState = await _state.WaitForActiveConnectionAsync(callerName, token: cancellationToken).ConfigureAwait(false);
1411result = await resultTask.ConfigureAwait(false);
1659closeMessage = await ProcessMessagesAsync(message, connectionState, invocationMessageChannel.Writer).ConfigureAwait(false);
Microsoft.AspNetCore.SignalR.Client.FunctionalTests (1)
Microsoft.AspNetCore.SignalR.Core (1)
Microsoft.AspNetCore.SignalR.Specification.Tests (2)
Microsoft.AspNetCore.SignalR.Tests.Utils (1)
Microsoft.AspNetCore.TestHost (1)
Microsoft.AspNetCore.WebUtilities (1)
Microsoft.Build (3)
Microsoft.Build.Tasks.CodeAnalysis (7)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
Microsoft.Build.Tasks.CodeAnalysis.Sdk (7)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
Microsoft.Build.Tasks.Core (3)
Microsoft.CodeAnalysis (43)
DiagnosticAnalyzer\AnalyzerDriver.cs (7)
409(_lazyAnalyzerActions, _lazyUnsuppressedAnalyzers) = await GetAnalyzerActionsAsync(Analyzers, AnalyzerManager, analyzerExecutor, analysisScope, _severityFilter, cancellationToken).ConfigureAwait(false);
410_lazyAnalyzerGateMap = await CreateAnalyzerGateMapAsync(UnsuppressedAnalyzers, AnalyzerManager, analyzerExecutor, analysisScope, _severityFilter, cancellationToken).ConfigureAwait(false);
413_lazyGeneratedCodeAnalysisFlagsMap = await CreateGeneratedCodeAnalysisFlagsMapAsync(UnsuppressedAnalyzers, AnalyzerManager, analyzerExecutor, analysisScope, _severityFilter, cancellationToken).ConfigureAwait(false);
1523workerTasks[i] = Task.Run(async () => await ProcessCompilationEventsCoreAsync(analysisScope, prePopulatedEventQueue, cancellationToken).ConfigureAwait(false));
1555completedEvent = await ProcessCompilationEventsCoreAsync(analysisScope, prePopulatedEventQueue, cancellationToken).ConfigureAwait(false);
2235var isConcurrent = await analyzerManager.IsConcurrentAnalyzerAsync(analyzer, analyzerExecutor, cancellationToken).ConfigureAwait(false);
2260var generatedCodeAnalysisFlags = await analyzerManager.GetGeneratedCodeAnalysisFlagsAsync(analyzer, analyzerExecutor, cancellationToken).ConfigureAwait(false);
DiagnosticAnalyzer\AnalyzerManager.cs (6)
79return await analyzerExecutionContext.GetCompilationAnalysisScopeAsync(sessionScope, analyzerExecutor, cancellationToken).ConfigureAwait(false);
103return await GetSymbolAnalysisScopeCoreAsync(symbol, isGeneratedCodeSymbol, filterTree, filterSpan, symbolStartActions, analyzerExecutor, analyzerExecutionContext, cancellationToken).ConfigureAwait(false);
118return await analyzerExecutionContext.GetSymbolAnalysisScopeAsync(symbol, isGeneratedCodeSymbol, filterTree, filterSpan, symbolStartActions, analyzerExecutor, cancellationToken).ConfigureAwait(false);
127return await GetSymbolAnalysisScopeCoreAsync(symbol, isGeneratedCodeSymbol, filterTree, filterSpan, symbolStartActions, analyzerExecutor, analyzerExecutionContext, cancellationToken).ConfigureAwait(false);
150return await task.ConfigureAwait(false);
201var symbolScope = await GetSymbolAnalysisScopeAsync(symbol, isGeneratedCodeSymbol, filterTree, filterSpan, analyzer, filteredSymbolStartActions, analyzerExecutor, cancellationToken).ConfigureAwait(false);
DiagnosticAnalyzer\CompilationWithAnalyzers.cs (25)
245return await GetAnalyzerDiagnosticsCoreAsync(Analyzers, cancellationToken).ConfigureAwait(false);
257return await GetAnalyzerDiagnosticsCoreAsync(analyzers, cancellationToken).ConfigureAwait(false);
265return await GetAnalysisResultCoreAsync(Analyzers, cancellationToken).ConfigureAwait(false);
277return await GetAnalysisResultCoreAsync(analyzers, cancellationToken).ConfigureAwait(false);
294var diagnostics = await getAllDiagnosticsWithoutStateTrackingAsync(Analyzers, cancellationToken: cancellationToken).ConfigureAwait(false);
309using var driver = await CreateAndInitializeDriverAsync(compilation, _analysisOptions, analysisScope, _suppressors, categorizeDiagnostics: false, cancellationToken).ConfigureAwait(false);
314var analyzerDiags = await driver.GetDiagnosticsAsync(compilation, cancellationToken).ConfigureAwait(false);
326return await GetAnalyzerCompilationDiagnosticsCoreAsync(Analyzers, cancellationToken).ConfigureAwait(false);
339return await GetAnalyzerCompilationDiagnosticsCoreAsync(analyzers, cancellationToken).ConfigureAwait(false);
399return await GetAnalyzerSyntaxDiagnosticsCoreAsync(tree, Analyzers, filterSpan: null, cancellationToken).ConfigureAwait(false);
415return await GetAnalyzerSyntaxDiagnosticsCoreAsync(tree, Analyzers, filterSpan, cancellationToken).ConfigureAwait(false);
432return await GetAnalyzerSyntaxDiagnosticsCoreAsync(tree, analyzers, filterSpan: null, cancellationToken).ConfigureAwait(false);
450return await GetAnalyzerSyntaxDiagnosticsCoreAsync(tree, analyzers, filterSpan, cancellationToken).ConfigureAwait(false);
524return await GetAnalysisResultCoreAsync(new SourceOrAdditionalFile(file), Analyzers, filterSpan: null, cancellationToken).ConfigureAwait(false);
540return await GetAnalysisResultCoreAsync(new SourceOrAdditionalFile(file), analyzers, filterSpan: null, cancellationToken).ConfigureAwait(false);
556return await GetAnalysisResultCoreAsync(new SourceOrAdditionalFile(file), Analyzers, filterSpan, cancellationToken).ConfigureAwait(false);
574return await GetAnalysisResultCoreAsync(new SourceOrAdditionalFile(file), analyzers, filterSpan, cancellationToken).ConfigureAwait(false);
602return await GetAnalyzerSemanticDiagnosticsCoreAsync(model, filterSpan, Analyzers, cancellationToken).ConfigureAwait(false);
618return await GetAnalyzerSemanticDiagnosticsCoreAsync(model, filterSpan, analyzers, cancellationToken).ConfigureAwait(false);
729using var driver = await CreateAndInitializeDriverAsync(compilation, _analysisOptions, analysisScope, _suppressors, categorizeDiagnostics: true, cancellationToken).ConfigureAwait(false);
736driver, compilation, analysisScope, cancellationToken).ConfigureAwait(false);
843var actionCounts = await driver.GetAnalyzerActionCountsAsync(analyzer, compilation.Options, analysisScope, cancellationToken).ConfigureAwait(false);
1282var actionCounts = await GetAnalyzerActionCountsAsync(analyzer, cancellationToken).ConfigureAwait(false);
1299using var driver = await CreateAndInitializeDriverAsync(_compilation, _analysisOptions, analysisScope, _suppressors, categorizeDiagnostics: true, cancellationToken).ConfigureAwait(false);
1301return await driver.GetAnalyzerActionCountsAsync(analyzer, _compilation.Options, analysisScope, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.Analyzers (101)
MetaAnalyzers\Fixers\CompareSymbolsCorrectlyFix.cs (7)
73IBinaryOperation binaryOperation => await ConvertToEqualsAsync(document, semanticModel, binaryOperation, cancellationToken).ConfigureAwait(false),
74IInvocationOperation invocationOperation => await EnsureEqualsCorrectAsync(document, semanticModel, invocationOperation, cancellationToken).ConfigureAwait(false),
98.ConfigureAwait(false),
104.ConfigureAwait(false),
124var editor = await DocumentEditor.CreateAsync(document, cancellationToken).ConfigureAwait(false);
193var editor = await DocumentEditor.CreateAsync(document, cancellationToken).ConfigureAwait(false);
259var editor = await DocumentEditor.CreateAsync(document, cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.AnalyzerUtilities (25)
Microsoft.CodeAnalysis.BannedApiAnalyzers (71)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CodeStyle (24)
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (6)
169idToSuppressMessageAttributesMap, suppressMessageAttributesToIsUsedMap, userIdExclusions, userCategoryExclusions, cancellationToken).ConfigureAwait(false);
187getSupportedDiagnostics, compilerDiagnosticIds, cancellationToken).ConfigureAwait(false);
464var analysisResult = await compilationWithAnalyzers.GetAnalysisResultAsync(semanticModel.SyntaxTree, analyzers, cancellationToken).ConfigureAwait(false);
471analysisResult = await compilationWithAnalyzers.GetAnalysisResultAsync(semanticModel, filterSpan: null, analyzers, cancellationToken).ConfigureAwait(false);
596var attributeNode = await attribute.ApplicationSyntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
819var attributeNode = await attribute.ApplicationSyntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CodeStyle.Fixes (182)
src\Analyzers\Core\CodeFixes\GenerateConstructor\AbstractGenerateConstructorService.State.cs (10)
71var parameterNamingRule = await document.Document.GetApplicableNamingRuleAsync(SymbolKind.Parameter, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false);
74if (!await state.TryInitializeAsync(node, cancellationToken).ConfigureAwait(false))
115if (!await TryInitializeDelegatedConstructorAsync(cancellationToken).ConfigureAwait(false))
131_document, this.TypeToGenerateIn, _arguments, ParameterTypes, parameterNames, cancellationToken).ConfigureAwait(false);
175_document, this.TypeToGenerateIn, remainingArguments, remainingParameterTypes, remainingParameterNames, cancellationToken).ConfigureAwait(false);
415return await GenerateThisOrBaseDelegatingConstructorAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false) ??
416await GenerateMemberDelegatingConstructorAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false);
427var (members, assignments) = await GenerateMembersAndAssignmentsAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false);
452cancellationToken).ConfigureAwait(false);
507cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\TypeParameterSubstitution.cs (4)
92(INamedTypeSymbol)symbol.ConstraintTypes[0], projects).ConfigureAwait(false);
97(INamedTypeSymbol)symbol.ConstraintTypes[i], projects).ConfigureAwait(false);
130symbol, solution, transitive: true, projects, _cancellationToken).ConfigureAwait(false);
133symbol, solution, transitive: true, projects, _cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.cs (6)
39var semanticDocument = await SemanticDocument.CreateAsync(document, cancellationToken).ConfigureAwait(false);
100document.Document, state, SymbolKind.Property, state.DetermineMaximalAccessibility(), cancellationToken).ConfigureAwait(false))
122var namingStyle = await document.GetApplicableNamingRuleAsync(kind, accessibility, cancellationToken).ConfigureAwait(false);
182document, state, SymbolKind.Local, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false))
198document, state, SymbolKind.Parameter, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false))
208var compilation = await document.Project.GetRequiredCompilationAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeMethodAsynchronous\AbstractMakeMethodAsynchronousCodeFixProvider.cs (4)
121? await RenameThenAddAsyncTokenAsync(keepVoid, document, node, methodSymbol, knownTypes, cancellationToken).ConfigureAwait(false)
122: await AddAsyncTokenAsync(keepVoid, document, methodSymbol, knownTypes, node, cancellationToken).ConfigureAwait(false);
169var newSolution = await Renamer.RenameSymbolAsync(solution, methodSymbol, new SymbolRenameOptions(), newName, cancellationToken).ConfigureAwait(false);
177return await AddAsyncTokenAsync(keepVoid, newDocument, newMethod, knownTypes, newNode, cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeMethodSynchronous\AbstractMakeMethodSynchronousCodeFixProvider.cs (10)
65return await RenameThenRemoveAsyncTokenAsync(document, node, methodSymbol, cancellationToken).ConfigureAwait(false);
69return await RemoveAsyncTokenAsync(document, methodSymbol, node, cancellationToken).ConfigureAwait(false);
83var newSolution = await Renamer.RenameSymbolAsync(solution, methodSymbol, new SymbolRenameOptions(), newName, cancellationToken).ConfigureAwait(false);
85var newRoot = await newDocument.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
90return await RemoveAsyncTokenAsync(newDocument, newMethod, newNode, cancellationToken).ConfigureAwait(false);
99var compilation = await document.Project.GetRequiredCompilationAsync(cancellationToken).ConfigureAwait(false);
116newDocument, annotation, cancellationToken).ConfigureAwait(false);
133methodSymbol, document.Project.Solution, cancellationToken).ConfigureAwait(false);
146document.Project.Solution, [.. referencedSymbol.Locations], cancellationToken).ConfigureAwait(false);
164currentSolution, group, cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnusedParametersAndValues\AbstractRemoveUnusedValuesCodeFixProvider.cs (13)
287var preprocessedDocument = await PreprocessDocumentAsync(document, diagnostics, cancellationToken).ConfigureAwait(false);
288var newRoot = await GetNewRootAsync(preprocessedDocument, formattingOptions, diagnostics, cancellationToken).ConfigureAwait(false);
336diagnosticId, preference, cancellationToken).ConfigureAwait(false);
638!(await IsLocalDeclarationWithNoReferencesAsync(localDeclarationStatement, document, cancellationToken).ConfigureAwait(false)))
759ReplaceDiscardDeclarationsWithAssignmentsAsync, currentRoot, document, options, cancellationToken).ConfigureAwait(false);
767AdjustLocalDeclarationsAsync, currentRoot, document, options, cancellationToken).ConfigureAwait(false);
789var newMemberDecl = await processMemberDeclarationAsync(memberDecl, newDocument, options, cancellationToken).ConfigureAwait(false);
811return await service.ReplaceAsync(document, memberDeclaration, cancellationToken).ConfigureAwait(false);
861if (await TryRemoveUnusedLocalAsync(declStatement, originalDeclStatement).ConfigureAwait(false))
872var (canUse, mayChangeSemantics) = await moveDeclarationService.CanMoveDeclarationNearReferenceAsync(document, declStatement, cancellationToken).ConfigureAwait(false);
875document = await moveDeclarationService.MoveDeclarationNearReferenceAsync(document, declStatement, cancellationToken).ConfigureAwait(false);
901if (await IsLocalDeclarationWithNoReferencesAsync(newDecl, document, cancellationToken).ConfigureAwait(false))
924var referencedSymbols = await SymbolFinder.FindReferencesAsync(local, document.Project.Solution, cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.Collections.Package (4)
Microsoft.CodeAnalysis.CSharp (1)
Microsoft.CodeAnalysis.CSharp.CodeStyle.Fixes (59)
src\Analyzers\CSharp\CodeFixes\MisplacedUsingDirectives\MisplacedUsingDirectivesCodeFixProvider.cs (5)
104document, compilationUnit, allUsingDirectives, placement, simplifierOptions, cancellationToken).ConfigureAwait(false);
147document, compilationUnit, allUsingDirectives, cancellationToken).ConfigureAwait(false);
163return await Simplifier.ReduceAsync(newDocument, Simplifier.Annotation, optionSet: null, cancellationToken).ConfigureAwait(false);
179await Task.WhenAll(expandUsingDirectiveTasks.Values).ConfigureAwait(false);
189var newType = await Simplifier.ExpandAsync(usingDirective.NamespaceOrType, document, cancellationToken: cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.CodeStyle.UnitTests (2)
Microsoft.CodeAnalysis.CSharp.EditorFeatures (11)
EventHookup\EventHookupCommandHandler_TabKeyCommand.cs (8)
127if (!await TryExecuteCommandAsync().ConfigureAwait(true))
156document, eventNameTask, initialCaretPoint.Position, cancellationToken).ConfigureAwait(true);
170var disposable = await waitContext.SuppressAutoCancelAsync().ConfigureAwait(true);
192var eventHandlerMethodName = await eventNameTask.WithCancellation(cancellationToken).ConfigureAwait(false);
198document, eventHandlerMethodName, position, cancellationToken).ConfigureAwait(false);
213documentWithNameAndAnnotationsAdded.WithSyntaxRoot(updatedRoot), Simplifier.Annotation, cleanupOptions.SimplifierOptions, cancellationToken).ConfigureAwait(false);
215simplifiedDocument, Formatter.Annotation, cleanupOptions.FormattingOptions, cancellationToken).ConfigureAwait(false);
263var newText = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.EditorFeatures.UnitTests (12)
Intents\IntentTestsBase.cs (3)
34var results = await GetIntentsAsync(workspace, intentName, currentDocumentText, options, intentData).ConfigureAwait(false);
61var results = await GetIntentsAsync(workspace, intentName, currentDocumentText, options, intentData).ConfigureAwait(false);
118var changes = await textDiffService.GetTextChangesAsync(currentDocument!, priorDocument, CancellationToken.None).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.Emit3.UnitTests (4)
Microsoft.CodeAnalysis.CSharp.Features (182)
Completion\CompletionProviders\OperatorsAndIndexer\UnnamedSymbolCompletionProvider.cs (3)
167IndexerKindName => await GetIndexerDescriptionAsync(document, item, displayOptions, cancellationToken).ConfigureAwait(false),
168OperatorKindName => await GetOperatorDescriptionAsync(document, item, displayOptions, cancellationToken).ConfigureAwait(false),
169ConversionKindName => await GetConversionDescriptionAsync(document, item, displayOptions, cancellationToken).ConfigureAwait(false),
Completion\CompletionProviders\OperatorsAndIndexer\UnnamedSymbolCompletionProvider_Conversions.cs (4)
134var conversion = await TryRehydrateAsync(document, item, cancellationToken).ConfigureAwait(false);
139item, document, [conversion], displayOptions, cancellationToken).ConfigureAwait(false);
147var symbols = await SymbolCompletionItem.GetSymbolsAsync(item, document, cancellationToken).ConfigureAwait(false);
162var symbols = await SymbolCompletionItem.GetSymbolsAsync(item, document, cancellationToken).ConfigureAwait(false);
Completion\CompletionProviders\SymbolCompletionProvider.cs (4)
91return !await IsTriggeredInArgumentListAsync(context, position, options, cancellationToken).ConfigureAwait(false);
105if (await IsTriggeredInArgumentListAsync(completionContext, position, options, cancellationToken).ConfigureAwait(false) is false)
126await IsTriggerInArgumentListAsync(completionContext.Document, position - 1, cancellationToken).ConfigureAwait(false) == true)
155result = await IsTriggerInArgumentListAsync(document, caretPosition - 1, cancellationToken).ConfigureAwait(false);
SignatureHelp\InvocationExpressionSignatureHelpProvider.cs (6)
71document, position, triggerInfo.TriggerReason, cancellationToken).ConfigureAwait(false);
83return await GetItemsWorkerForDelegateOrFunctionPointerAsync(document, position, invocationExpression, within, cancellationToken).ConfigureAwait(false);
110methods, document, invocationExpression, semanticModel, symbolInfo, currentSymbol, cancellationToken).ConfigureAwait(false);
114document, position, textSpan, cancellationToken).ConfigureAwait(false);
160document, position, textSpan, cancellationToken).ConfigureAwait(false);
171document, position, SignatureHelpTriggerReason.InvokeSignatureHelpCommand, cancellationToken).ConfigureAwait(false);
SignatureHelp\ObjectCreationExpressionSignatureHelpProvider.cs (5)
65document, position, triggerInfo.TriggerReason, cancellationToken).ConfigureAwait(false);
78return await GetItemsWorkerForDelegateAsync(document, position, objectCreationExpression, type, cancellationToken).ConfigureAwait(false);
106document, position, textSpan, cancellationToken).ConfigureAwait(false);
130document, position, textSpan, cancellationToken).ConfigureAwait(false);
138document, position, SignatureHelpTriggerReason.InvokeSignatureHelpCommand, cancellationToken).ConfigureAwait(false);
src\Analyzers\CSharp\CodeFixes\MisplacedUsingDirectives\MisplacedUsingDirectivesCodeFixProvider.cs (5)
104document, compilationUnit, allUsingDirectives, placement, simplifierOptions, cancellationToken).ConfigureAwait(false);
147document, compilationUnit, allUsingDirectives, cancellationToken).ConfigureAwait(false);
166return await Simplifier.ReduceAsync(newDocument, Simplifier.Annotation, simplifierOptions, cancellationToken).ConfigureAwait(false);
179await Task.WhenAll(expandUsingDirectiveTasks.Values).ConfigureAwait(false);
189var newType = await Simplifier.ExpandAsync(usingDirective.NamespaceOrType, document, cancellationToken: cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.CSharp.Features.UnitTests (3)
Microsoft.CodeAnalysis.CSharp.Workspaces (9)
Microsoft.CodeAnalysis.CSharp.Workspaces.UnitTests (4)
Microsoft.CodeAnalysis.EditorFeatures (192)
CodeActions\CodeActionEditHandlerService.cs (8)
58oldSolution, cancellationToken: cancellationToken).ConfigureAwait(false);
144workspace, originalSolution, progressTracker, cancellationToken).ConfigureAwait(true);
170workspace, originalSolution, operations, progressTracker, cancellationToken).ConfigureAwait(true);
283applied &= await operation.TryApplyAsync(workspace, originalSolution, progressTracker, cancellationToken).ConfigureAwait(true);
301this._threadingContext, workspace, navigationOperation.DocumentId, navigationOperation.Position, cancellationToken).ConfigureAwait(false);
310this._threadingContext, workspace, renameOperation.DocumentId, renameOperation.Position, cancellationToken).ConfigureAwait(true))
332this._threadingContext, workspace, documentId, navigationToken.Value.SpanStart, cancellationToken).ConfigureAwait(false);
357this._threadingContext, editorWorkspace, documentId, resolvedRenameToken.Span, cancellationToken).ConfigureAwait(false))
CodeDefinitionWindow\DefinitionContextTracker.cs (6)
125if (!await _codeDefinitionWindowService.IsWindowOpenAsync(cancellationToken).ConfigureAwait(false))
133var locations = await GetContextFromPointAsync(document, lastPoint, cancellationToken).ConfigureAwait(true);
146var navigableItems = await GetNavigableItemsAsync(document, position, cancellationToken).ConfigureAwait(false);
153if (await navigationService.CanNavigateToSpanAsync(workspace, item.Document.Id, item.SourceSpan, cancellationToken).ConfigureAwait(false))
169document, position, cancellationToken: cancellationToken).ConfigureAwait(false);
175var result = await symbolNavigationService.GetExternalNavigationSymbolLocationAsync(definitionItem, cancellationToken).ConfigureAwait(false);
DocumentationComments\CopilotGenerateDocumentationCommentProvider.cs (4)
45_suggestionManager ??= await suggestionServiceBase.TryRegisterProviderAsync(this, textView, "AmbientAIDocumentationComments", cancellationToken).ConfigureAwait(false);
70var intelliCodeLineCompletionsDisposable = await _suggestionManager.DisableProviderAsync(SuggestionServiceNames.IntelliCodeLineCompletions, cancellationToken).ConfigureAwait(false);
76snippetProposal, _copilotService, oldSnapshot, snippet.IndentText, cancellationToken).ConfigureAwait(false);
188var (documentationCommentDictionary, isQuotaExceeded) = await copilotService.GetDocumentationCommentAsync(proposal, cancellationToken).ConfigureAwait(false);
GoToDefinition\GoToDefinitionHelpers.cs (3)
25symbol, solution, threadingContext, streamingPresenter, cancellationToken, thirdPartyNavigationAllowed).ConfigureAwait(false);
27threadingContext, new NavigationOptions(PreferProvisionalTab: true, ActivateTab: true), cancellationToken).ConfigureAwait(false);
45threadingContext, solution.Workspace, title, definitions, cancellationToken).ConfigureAwait(false);
InlineRename\InlineRenameSession.cs (10)
319await AllRenameLocationsTask.JoinAsync(cancellationToken).ConfigureAwait(false);
322var inlineRenameLocations = await RenameInfo.FindRenameLocationsAsync(currentOptions, cancellationToken).ConfigureAwait(false);
550var result = await AllRenameLocationsTask.JoinAsync(cancellationToken).ConfigureAwait(false);
553return await result.GetReplacementsAsync(replacementText, options, cancellationToken).ConfigureAwait(false);
573var replacementInfo = await _conflictResolutionTask.JoinAsync(CancellationToken.None).ConfigureAwait(false);
581var computedMergeResult = await ComputeMergeResultAsync(replacementInfo, cancellationToken).ConfigureAwait(false);
773await CommitWorkerAsync(previewChanges, canUseBackgroundWorkIndicator: true, editorOperationContext).ConfigureAwait(false);
875var info = await _conflictResolutionTask.JoinAsync(cancellationToken).ConfigureAwait(true);
906var documentChanges = await CalculateFinalDocumentChangesAsync(newSolution, cancellationToken).ConfigureAwait(false);
949: (documentId, newDocument.Name, newRoot: null, await newDocument.GetTextAsync(cancellationToken).ConfigureAwait(false)));
Navigation\AbstractDefinitionLocationService.cs (5)
69document, controlFlowTarget.Value, cancellationToken).ConfigureAwait(false);
85project, position, symbol, originalDocument: document, cancellationToken).ConfigureAwait(false);
90symbol, position, document, cancellationToken).ConfigureAwait(false);
105_threadingContext, solution.Workspace, title, allDefinitions, cancellationToken).ConfigureAwait(false);
169_threadingContext, solution.Workspace, title, definitions, cancellationToken).ConfigureAwait(false);
Navigation\IDocumentNavigationServiceExtensions.cs (6)
34return await location.TryNavigateToAsync(threadingContext, options, cancellationToken).ConfigureAwait(false);
41return await location.TryNavigateToAsync(threadingContext, options, cancellationToken).ConfigureAwait(false);
48return await location.TryNavigateToAsync(threadingContext, NavigationOptions.Default, cancellationToken).ConfigureAwait(false);
55return await location.TryNavigateToAsync(threadingContext, options, cancellationToken).ConfigureAwait(false);
69return await location.TryNavigateToAsync(threadingContext, options, cancellationToken).ConfigureAwait(false);
96return location != null && await location.TryNavigateToAsync(threadingContext, options, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.EditorFeatures.Test.Utilities (5)
RefactoringHelpers\RefactoringHelpersTestBase.cs (4)
35var resultNode = await GetNodeForSelectionAsync(text, selection, predicate, allowEmptyNodes).ConfigureAwait(false);
44var resultNode = await GetNodeForSelectionAsync(text, selection, Functions<TNode>.True).ConfigureAwait(false);
53var resultNode = await GetNodeForSelectionAsync(text, selection, Functions<TNode>.True).ConfigureAwait(false);
67var resultNode = await GetNodeForSelectionAsync(text, selection, predicate, allowEmptyNodes).ConfigureAwait(false);
Microsoft.CodeAnalysis.EditorFeatures.UnitTests (8)
Microsoft.CodeAnalysis.EditorFeatures2.UnitTests (5)
Microsoft.CodeAnalysis.Extensions.Package (4)
Microsoft.CodeAnalysis.ExternalAccess.AspNetCore (2)
Microsoft.CodeAnalysis.ExternalAccess.Copilot (17)
Internal\Analyzer\AbstractCopilotCodeAnalysisService.cs (16)
63return await GetAvailablePromptTitlesCoreAsync(document, cancellationToken).ConfigureAwait(false);
82if (await ShouldSkipAnalysisAsync(document, cancellationToken).ConfigureAwait(false))
88if (!await IsAvailableAsync(cancellationToken).ConfigureAwait(false))
92var diagnostics = await AnalyzeDocumentCoreAsync(document, span, promptTitle, cancellationToken).ConfigureAwait(false);
137if (await ShouldSkipAnalysisAsync(document, cancellationToken).ConfigureAwait(false))
157var cachedDiagnostics = await GetCachedDiagnosticsCoreAsync(document, promptTitle, cancellationToken).ConfigureAwait(false);
164return await GetDiagnosticsIntersectWithSpanAsync(document, diagnostics, span.Value, cancellationToken).ConfigureAwait(false);
185return await GetOnTheFlyDocsPromptCoreAsync(onTheFlyDocsInfo, cancellationToken).ConfigureAwait(false);
189if (!await IsAvailableAsync(cancellationToken).ConfigureAwait(false))
192return await GetOnTheFlyDocsResponseCoreAsync(prompt, cancellationToken).ConfigureAwait(false);
197if (!await IsAvailableAsync(cancellationToken).ConfigureAwait(false))
200return await IsFileExcludedCoreAsync(filePath, cancellationToken).ConfigureAwait(false);
205if (!await IsAvailableAsync(cancellationToken).ConfigureAwait(false))
208return await GetDocumentationCommentCoreAsync(proposal, cancellationToken).ConfigureAwait(false);
213return await IsAvailableAsync(cancellationToken).ConfigureAwait(false)
222return await ImplementNotImplementedExceptionsCoreAsync(document, methodOrProperties, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.ExternalAccess.FSharp (32)
Microsoft.CodeAnalysis.ExternalAccess.OmniSharp (1)
Microsoft.CodeAnalysis.ExternalAccess.Razor.Features (7)
Microsoft.CodeAnalysis.ExternalAccess.Xaml (4)
Microsoft.CodeAnalysis.Features (1149)
AddImport\AbstractAddImportFeatureService.cs (7)
85packageSources, cancellationToken).ConfigureAwait(false);
109options, packageSources, cancellationToken).ConfigureAwait(false);
152var exactReferences = await FindResultsAsync(projectToAssembly, referenceToCompilation, project, maxResults, finder, exact: true, cancellationToken).ConfigureAwait(false);
162var fuzzyReferences = await FindResultsAsync(projectToAssembly, referenceToCompilation, project, maxResults, finder, exact: false, cancellationToken).ConfigureAwait(false);
211await finder.FindInAllSymbolsInStartingProjectAsync(exact, cancellationToken).ConfigureAwait(false));
529packageSources, cancellationToken).ConfigureAwait(false);
558packageSources, cancellationToken).ConfigureAwait(false);
AddImport\SymbolReferenceFinder.cs (12)
195var symbols = await searchScope.FindDeclarationsAsync(name, nameNode, SymbolFilter.Type, cancellationToken).ConfigureAwait(false);
201name + AttributeSuffix, nameNode, SymbolFilter.Type, cancellationToken).ConfigureAwait(false);
273var symbols = await searchScope.FindDeclarationsAsync(name, nameNode, SymbolFilter.Namespace, cancellationToken).ConfigureAwait(false);
319symbol.Name, simpleName, SymbolFilter.Type, cancellationToken).ConfigureAwait(false);
368var symbols = await searchScope.FindDeclarationsAsync(name, nameNode, SymbolFilter.Member, cancellationToken).ConfigureAwait(false);
421nameof(IList.Add), nameNode: null, filter: SymbolFilter.Member, cancellationToken).ConfigureAwait(false);
455searchScope, nameof(Enumerable.Select), type, predicate: null, cancellationToken).ConfigureAwait(false);
480cancellationToken).ConfigureAwait(false);
505cancellationToken).ConfigureAwait(false);
530cancellationToken).ConfigureAwait(false);
557searchScope, "Deconstruct", type, static m => m.ReturnsVoid, cancellationToken).ConfigureAwait(false);
568name, nameNode: null, filter: SymbolFilter.Member, cancellationToken).ConfigureAwait(false);
ChangeSignature\AbstractChangeSignatureService.cs (10)
96var context = await GetChangeSignatureContextAsync(document, span.Start, restrictToDeclarations: true, cancellationToken).ConfigureAwait(false);
107document, position, restrictToDeclarations, cancellationToken).ConfigureAwait(false);
110symbol = await SymbolFinder.FindSourceDefinitionAsync(symbol, document.Project.Solution, cancellationToken).ConfigureAwait(false) ?? symbol;
170var syntax = await reference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
194ChangeSignatureAnalysisSucceededContext changeSignatureAnalyzedSucceedContext => await GetChangeSignatureResultAsync(changeSignatureAnalyzedSucceedContext, options, cancellationToken).ConfigureAwait(false),
206var (updatedSolution, confirmationMessage) = await CreateUpdatedSolutionAsync(context, options, cancellationToken).ConfigureAwait(false);
260declaredSymbol, context.Solution, cancellationToken).ConfigureAwait(false);
426var docWithImports = await ImportAdder.AddImportsFromSymbolAnnotationAsync(updatedDoc, cleanupOptions.AddImportOptions, cancellationToken).ConfigureAwait(false);
427var reducedDoc = await Simplifier.ReduceAsync(docWithImports, Simplifier.Annotation, cleanupOptions.SimplifierOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
428var formattedDoc = await Formatter.FormatAsync(reducedDoc, SyntaxAnnotation.ElasticAnnotation, cleanupOptions.FormattingOptions, cancellationToken).ConfigureAwait(false);
ClassifiedSpansAndHighlightSpanFactory.cs (4)
28documentSpan.Document, documentSpan.SourceSpan, options, cancellationToken).ConfigureAwait(false);
40document, narrowSpan, lineSpan, options, cancellationToken).ConfigureAwait(false);
64document, narrowSpan, widenedSpan, options, cancellationToken).ConfigureAwait(false);
74document, widenedSpan, options, includeAdditiveSpans: false, cancellationToken).ConfigureAwait(false);
CodeFixes\Service\CodeFixService.cs (13)
111priorityProvider, DiagnosticKind.All, cancellationToken).ConfigureAwait(false);
119var copilotDiagnostics = await GetCopilotDiagnosticsAsync(document, range, priorityProvider.Priority, cancellationToken).ConfigureAwait(false);
148var collection = await errorFixTask.ConfigureAwait(false) ??
149await otherFixTask.ConfigureAwait(false);
203priorityProvider, DiagnosticKind.All, cancellationToken).ConfigureAwait(false);
208var copilotDiagnostics = await GetCopilotDiagnosticsAsync(document, range, priorityProvider.Priority, cancellationToken).ConfigureAwait(false);
258return await document.GetCachedCopilotDiagnosticsAsync(range, cancellationToken).ConfigureAwait(false);
305DiagnosticKind.All, cancellationToken).ConfigureAwait(false);
352document, textSpan, diagnosticId, severity, cancellationToken).ConfigureAwait(false);
361new FixAllContext(fixCollection.FixAllState!, progressTracker, cancellationToken)).ConfigureAwait(false);
570cancellationToken).ConfigureAwait(false);
734var fixes = await provider.GetFixesAsync(document, diagnosticsSpan, dxs, cancellationToken).ConfigureAwait(false);
737cancellationToken).ConfigureAwait(false);
CodeFixes\Service\CodeFixService.FixAllDiagnosticProvider.cs (4)
48document.Project, document.Id, _diagnosticIds, shouldIncludeAnalyzer: null, includeLocalDocumentDiagnostics: true, includeNonLocalDocumentDiagnostics: false, cancellationToken).ConfigureAwait(false));
61DiagnosticKind.All, cancellationToken).ConfigureAwait(false));
71project, documentId: null, _diagnosticIds, shouldIncludeAnalyzer: null, includeLocalDocumentDiagnostics: true, includeNonLocalDocumentDiagnostics: false, cancellationToken).ConfigureAwait(false));
80project, _diagnosticIds, shouldIncludeAnalyzer: null, includeNonLocalDocumentDiagnostics: false, cancellationToken).ConfigureAwait(false));
CodeFixes\Suppression\AbstractSuppressionBatchFixAllProvider.cs (12)
34var documentsAndDiagnosticsToFixMap = await fixAllContext.GetDocumentDiagnosticsToFixAsync().ConfigureAwait(false);
35return await GetFixAsync(documentsAndDiagnosticsToFixMap, fixAllContext).ConfigureAwait(false);
39var projectsAndDiagnosticsToFixMap = await fixAllContext.GetProjectDiagnosticsToFixAsync().ConfigureAwait(false);
40return await GetFixAsync(projectsAndDiagnosticsToFixMap, fixAllContext).ConfigureAwait(false);
57var diagnosticsAndCodeActions = await GetDiagnosticsAndCodeActionsAsync(documentsAndDiagnosticsToFixMap, fixAllContext).ConfigureAwait(false);
66diagnosticsAndCodeActions, fixAllState, progressTracker, cancellationToken).ConfigureAwait(false);
167result, fixAllState, progressTracker, cancellationToken).ConfigureAwait(false);
215solution, batchOfFixes, progressTracker, cancellationToken).ConfigureAwait(false);
232oldSolution, diagnosticsAndCodeActions, progressTracker, cancellationToken).ConfigureAwait(false);
240diagnosticsAndCodeActions, cancellationToken).ConfigureAwait(false);
336var newText = await merger.GetFinalMergedTextAsync(cancellationToken).ConfigureAwait(false);
353oldSolution, progressTracker, cancellationToken: cancellationToken).ConfigureAwait(false);
CodeFixes\Suppression\AbstractSuppressionCodeFixProvider.cs (10)
151var codeFixes = await GetSuppressionsAsync(document, span, diagnostics, skipSuppressMessage: true, skipUnsuppress: true, cancellationToken: cancellationToken).ConfigureAwait(false);
158var suppressionTargetInfo = await GetSuppressionTargetInfoAsync(document, span, cancellationToken).ConfigureAwait(false);
165document, document.Project, diagnostics, suppressionTargetInfo, skipSuppressMessage, skipUnsuppress, cancellationToken).ConfigureAwait(false);
176var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
181cancellationToken).ConfigureAwait(false);
197var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
242var codeAction = await RemoveSuppressionCodeAction.CreateAsync(suppressionTargetInfo, documentOpt, project, diagnostic, this, cancellationToken).ConfigureAwait(false);
264var syntaxTree = await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
271var root = await syntaxTree.GetRootAsync(cancellationToken).ConfigureAwait(false);
287var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
CodeFixes\Suppression\AbstractSuppressionCodeFixProvider.PragmaBatchFixHelpers.cs (6)
69var currentTree = await currentDocument.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
88var newSuppressionFixes = await suppressionFixProvider.GetFixesAsync(currentDocument, currentDiagnosticSpan, [diagnostic], cancellationToken).ConfigureAwait(false);
100includeStartTokenChange: true, includeEndTokenChange: false, cancellationToken: cancellationToken).ConfigureAwait(false);
103includeStartTokenChange: false, includeEndTokenChange: true, cancellationToken: cancellationToken).ConfigureAwait(false);
126var newDocument = await pragmaAction.GetChangedDocumentAsync(includeStartTokenChange, includeEndTokenChange, cancellationToken).ConfigureAwait(false);
127return await newDocument.GetTextChangesAsync(currentDocument, cancellationToken).ConfigureAwait(false);
CodeFixesAndRefactorings\AbstractFixAllGetFixesService.cs (6)
27var codeAction = await GetFixAllCodeActionAsync(fixAllContext).ConfigureAwait(false);
34return await codeAction.GetChangedSolutionInternalAsync(fixAllContext.State.Solution, fixAllContext.Progress, fixAllContext.CancellationToken).ConfigureAwait(false);
40var codeAction = await GetFixAllCodeActionAsync(fixAllContext).ConfigureAwait(false);
47codeAction, showPreviewChangesDialog, fixAllContext.Progress, fixAllContext.State, fixAllContext.CancellationToken).ConfigureAwait(false);
64fixAllState.Solution, progressTracker, cancellationToken).ConfigureAwait(false);
72fixAllState.Solution, progressTracker, cancellationToken).ConfigureAwait(false);
CodeLens\CodeLensReferencesService.cs (11)
66symbol, solution, progress, documents: null, s_nonParallelSearch, progress.CancellationToken).ConfigureAwait(false);
68return await onResults(progress).ConfigureAwait(false);
75return await onCapped(progress).ConfigureAwait(false);
98maxSearchResults, cancellationToken).ConfigureAwait(false);
110var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
119var token = (await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false)).FindToken(position, true);
211var result = await Task.WhenAll(referenceTasks).ConfigureAwait(false);
214}, onCapped: null, searchCap: 0, cancellationToken: cancellationToken).ConfigureAwait(false);
253var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
269var result = await Task.WhenAll(descriptorTasks).ConfigureAwait(false);
280var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
CodeRefactorings\AddMissingImports\AbstractAddMissingImportsFeatureService.cs (5)
124newDocument, insertSpans, formattingOptions, cancellationToken).ConfigureAwait(false);
145newDocument = await CleanUpNewLinesAsync(newDocument, insertSpan, formattingOptions, cancellationToken).ConfigureAwait(false);
202document.Project.Solution, progressTracker, cancellationToken).ConfigureAwait(false);
214newSolution = await codeAction.GetRequiredChangedSolutionAsync(progressTracker, cancellationToken).ConfigureAwait(false);
222document, newDocument, TextDifferenceTypes.Line, cancellationToken).ConfigureAwait(false);
CodeRefactorings\ExtractMethod\AbstractExtractMethodCodeRefactoringProvider.cs (11)
49var actions = await GetCodeActionsAsync(document, textSpan, extractOptions, cancellationToken).ConfigureAwait(false);
60var methodAction = await ExtractMethodAsync(document, textSpan, extractOptions, cancellationToken).ConfigureAwait(false);
63var localFunctionAction = await ExtractLocalFunctionAsync(document, textSpan, extractOptions, cancellationToken).ConfigureAwait(false);
77cancellationToken).ConfigureAwait(false);
88var (document, invocationNameToken) = await result.GetDocumentAsync(cancellationToken).ConfigureAwait(false);
89return await AddRenameAnnotationAsync(document, invocationNameToken, cancellationToken).ConfigureAwait(false);
97var syntaxTree = await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
109cancellationToken).ConfigureAwait(false);
119var (document, invocationNameToken) = await localFunctionResult.GetDocumentAsync(cancellationToken).ConfigureAwait(false);
120return await AddRenameAnnotationAsync(document, invocationNameToken, cancellationToken).ConfigureAwait(false);
131var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
CodeRefactorings\MoveType\AbstractMoveTypeService.MoveTypeEditor.cs (8)
64var documentWithMovedType = await AddNewDocumentWithSingleTypeDeclarationAsync(newDocumentId).ConfigureAwait(false);
73var solutionWithBothDocumentsUpdated = await RemoveTypeFromSourceDocumentAsync(sourceDocument).ConfigureAwait(false);
75return await RemoveUnnecessaryImportsAsync(solutionWithBothDocumentsUpdated, sourceDocument.Id, documentWithMovedType.Id).ConfigureAwait(false);
121var documentEditor = await DocumentEditor.CreateAsync(document, CancellationToken).ConfigureAwait(false);
157modifiedRoot = await AddFinalNewLineIfDesiredAsync(document, modifiedRoot).ConfigureAwait(false);
167newDocument, FileName, document, this.CancellationToken).ConfigureAwait(false);
233var documentEditor = await DocumentEditor.CreateAsync(sourceDocument, CancellationToken).ConfigureAwait(false);
245updatedDocument = await AddFileBannerHelpers.CopyBannerAsync(updatedDocument, sourceDocument.FilePath, sourceDocument, this.CancellationToken).ConfigureAwait(false);
CodeRefactorings\SyncNamespace\AbstractChangeNamespaceService.cs (30)
122var applicableContainers = await GetValidContainersFromAllLinkedDocumentsAsync(document, container, cancellationToken).ConfigureAwait(false);
137var originalNamespaceDeclarations = await GetTopLevelNamespacesAsync(document, cancellationToken).ConfigureAwait(false);
162var namespaces = await GetTopLevelNamespacesAsync(document, cancellationToken).ConfigureAwait(false);
166solution = await ChangeNamespaceAsync(document, namespaceToRename, targetNamespace, cancellationToken).ConfigureAwait(false);
203var containersFromAllDocuments = await GetValidContainersFromAllLinkedDocumentsAsync(document, container, cancellationToken).ConfigureAwait(false);
213var annotatedSolution = await AnnotateContainersAsync(solution, containersFromAllDocuments, cancellationToken).ConfigureAwait(false);
230solutionAfterNamespaceChange, documentId, declaredNamespace, targetNamespace, cancellationToken).ConfigureAwait(false);
235var solutionAfterFirstMerge = await MergeDiffAsync(solution, solutionAfterNamespaceChange, cancellationToken).ConfigureAwait(false);
258cancellationToken).ConfigureAwait(false);
264cancellationToken).ConfigureAwait(false);
266return await MergeDiffAsync(solutionAfterFirstMerge, solutionAfterImportsRemoved, cancellationToken).ConfigureAwait(false);
286var container = await TryGetApplicableContainerFromSpanAsync(document, span, cancellationToken).ConfigureAwait(false);
317var documentEditor = await solutionEditor.GetDocumentEditorAsync(id, cancellationToken).ConfigureAwait(false);
441var declaredSymbols = await GetDeclaredSymbolsInContainerAsync(document, container, cancellationToken).ConfigureAwait(false);
443var editor = await DocumentEditor.CreateAsync(document, cancellationToken).ConfigureAwait(false);
470document, refLocationsInCurrentDocument, oldNamespace, newNamespace, cancellationToken).ConfigureAwait(false);
497cancellationToken).ConfigureAwait(false);
512var referencedSymbols = await FindReferencesAsync(symbol, document, cancellationToken).ConfigureAwait(false);
530var referencedMethodSymbols = await FindReferencesAsync(methodSymbol, document, cancellationToken).ConfigureAwait(false);
547FindReferencesSearchOptions.Default, cancellationToken).ConfigureAwait(false);
588document, this, addImportService, refLocations, newNamespaceParts, cancellationToken).ConfigureAwait(false);
613cancellationToken).ConfigureAwait(false);
636return await SimplifyTypeNamesAsync(formattedDocument, documentOptions, cancellationToken).ConfigureAwait(false);
689document, changeNamespaceService, addImportService, refLocations, newNamespaceParts, cancellationToken).ConfigureAwait(false);
699cancellationToken).ConfigureAwait(false);
703documentWithAdditionalImports, Formatter.Annotation, documentOptions.FormattingOptions, cancellationToken).ConfigureAwait(false);
705return await SimplifyTypeNamesAsync(formattedDocument, documentOptions, cancellationToken).ConfigureAwait(false);
712var text = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
738var editor = await DocumentEditor.CreateAsync(document, cancellationToken).ConfigureAwait(false);
827cancellationToken).ConfigureAwait(false);
Completion\CommonCompletionProvider.cs (4)
69var description = await GetDescriptionWorkerAsync(document, item, options, displayOptions, cancellationToken).ConfigureAwait(false);
70var parts = await TryAddSnippetInvocationPartAsync(document, item, description.TaggedParts, cancellationToken).ConfigureAwait(false);
82var change = await GetTextChangeAsync(document, item, ch: '\t', cancellationToken: cancellationToken).ConfigureAwait(false) ??
112var change = (await GetTextChangeAsync(document, item, commitKey, cancellationToken).ConfigureAwait(false))
Completion\CompletionService_GetCompletions.cs (5)
73var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
88var additionalAugmentingProviders = await GetAugmentingProvidersAsync(document, triggeredProviders, caretPosition, trigger, options, cancellationToken).ConfigureAwait(false);
98document, caretPosition, trigger, options, completionListSpan, triggeredProviders, sharedContext, cancellationToken).ConfigureAwait(false);
117document, caretPosition, trigger, options, completionListSpan, augmentingProviders, sharedContext, cancellationToken).ConfigureAwait(false);
244provider, document, caretPosition, trigger, options, completionListSpan, sharedContext, cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractAwaitCompletionProvider.cs (4)
88var syntaxContext = await context.GetSyntaxContextWithExistingSpeculativeModelAsync(document, cancellationToken).ConfigureAwait(false);
168return await base.GetChangeAsync(document, item, commitKey, cancellationToken).ConfigureAwait(false);
187return await base.GetChangeAsync(document, item, commitKey, cancellationToken).ConfigureAwait(false);
199document, leftTokenPosition, "System.Threading.Tasks", cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractCrefCompletionProvider.cs (2)
31var (token, semanticModel, symbols) = await GetSymbolsAsync(document, position, options, cancellationToken).ConfigureAwait(false);
42return await SymbolCompletionItem.GetDescriptionAsync(item, bestSymbols, document, semanticModel, displayOptions, cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractInternalsVisibleToCompletionProvider.cs (8)
60var syntaxTree = await context.Document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
71if (await CheckTypeInfoOfAttributeAsync(context.Document, attributeSyntaxNode, context.CancellationToken).ConfigureAwait(false))
136var allInternalsVisibleToAttributesOfProject = await GetAllInternalsVisibleToAssemblyNamesOfProjectAsync(context, cancellationToken).ConfigureAwait(false);
167context.Document, context.CompletionListSpan, cancellationToken).ConfigureAwait(false);
202if (await CheckTypeInfoOfAttributeAsync(document, attribute, completionContext.CancellationToken).ConfigureAwait(false))
212var assemblyName = await GetAssemblyNameFromInternalsVisibleToAttributeAsync(document, attribute, completionContext.CancellationToken).ConfigureAwait(false);
274var publicKey = await GetPublicKeyOfProjectAsync(project, cancellationToken).ConfigureAwait(false);
286var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractMemberInsertingCompletionProvider.cs (8)
50var (newDocument, newSpan) = await DetermineNewDocumentAsync(document, item, cancellationToken).ConfigureAwait(false);
53var changes = await newDocument.GetTextChangesAsync(document, cancellationToken).ConfigureAwait(false);
103var memberContainingDocument = await GenerateMemberAndUsingsAsync(document, completionItem, line, cancellationToken).ConfigureAwait(false);
114var result = await RemoveDestinationNodeAsync(memberContainingDocument, memberContainingDocumentCleanupOptions, cancellationToken).ConfigureAwait(false);
132var symbols = await SymbolCompletionItem.GetSymbolsAsync(completionItem, document, cancellationToken).ConfigureAwait(false);
147document, completionItem, semanticModel.Compilation, member, containingType, cancellationToken).ConfigureAwait(false);
223document = await Simplifier.ReduceAsync(document, Simplifier.Annotation, cleanupOptions.SimplifierOptions, cancellationToken).ConfigureAwait(false);
224document = await Formatter.FormatAsync(document, Formatter.Annotation, cleanupOptions.FormattingOptions, cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractRecommendationServiceBasedCompletionProvider.cs (8)
35var shouldProvideSymbols = await ShouldProvideAvailableSymbolsInCurrentContextAsync(completionContext, context, position, options, cancellationToken).ConfigureAwait(false);
58var shouldPreselectInferredTypes = await ShouldPreselectInferredTypesAsync(completionContext, position, options, cancellationToken).ConfigureAwait(false);
209var description = await TryGetDescriptionAsync(document.Id).ConfigureAwait(false);
220description = await TryGetDescriptionAsync(relatedId).ConfigureAwait(false);
230var context = await Utilities.CreateSyntaxContextWithExistingSpeculativeModelAsync(relatedDocument, position, cancellationToken).ConfigureAwait(false) as TSyntaxContext;
232var symbols = await TryGetSymbolsForContextAsync(completionContext: null, context, options, cancellationToken).ConfigureAwait(false);
250return await SymbolCompletionItem.GetDescriptionAsync(item, bestSymbols.SelectAsArray(t => t.Symbol), document, context.SemanticModel, displayOptions, cancellationToken).ConfigureAwait(false);
265var result = await IsTriggerOnDotAsync(document, characterPosition, cancellationToken).ConfigureAwait(false);
Completion\Providers\AbstractSymbolCompletionProvider.cs (6)
315var isSemanticTriggerCharacter = await IsSemanticTriggerCharacterAsync(document, position - 1, cancellationToken).ConfigureAwait(false);
326var syntaxContext = await completionContext.GetSyntaxContextWithExistingSpeculativeModelAsync(document, cancellationToken).ConfigureAwait(false) as TSyntaxContext;
329var regularItems = await GetItemsAsync(completionContext, syntaxContext, document, position, options, cancellationToken).ConfigureAwait(false);
351var itemsForCurrentDocument = await GetSymbolsAsync(completionContext, syntaxContext, position, options, cancellationToken).ConfigureAwait(false);
360var contextAndSymbolLists = await GetPerContextSymbolsAsync(completionContext, document, options, documentIdToIndex.Keys, cancellationToken).ConfigureAwait(false);
444: await GetSymbolsAsync(completionContext, syntaxContext, syntaxContext.Position, options, cancellationToken).ConfigureAwait(false);
Completion\Providers\Snippets\AbstractSnippetCompletionProvider.cs (5)
26var (strippedDocument, position) = await GetDocumentWithoutInvokingTextAsync(document, SnippetCompletionItem.GetInvocationPosition(item), cancellationToken).ConfigureAwait(false);
44var allTextChanges = await allChangesDocument.GetTextChangesAsync(document, cancellationToken).ConfigureAwait(false);
49var lspSnippet = await RoslynLSPSnippetConverter.GenerateLSPSnippetAsync(allChangesDocument, snippetChange.FinalCaretPosition, snippetChange.Placeholders, change, item.Span.Start, cancellationToken).ConfigureAwait(false);
83var syntaxContext = await context.GetSyntaxContextWithExistingSpeculativeModelAsync(document, cancellationToken).ConfigureAwait(false);
104return await Task.FromResult(CommonCompletionItem.GetDescription(item)).ConfigureAwait(false);
Completion\Providers\SymbolCompletionItem.cs (4)
187var symbols = await GetSymbolsAsync(item, document, cancellationToken).ConfigureAwait(false);
188return await GetDescriptionForSymbolsAsync(item, document, symbols, options, cancellationToken).ConfigureAwait(false);
206return await CommonCompletionUtilities.CreateDescriptionAsync(services, semanticModel, position, symbols, options, supportedPlatforms, cancellationToken).ConfigureAwait(false);
397return await CommonCompletionUtilities.CreateDescriptionAsync(document.Project.Solution.Services, semanticModel, position, symbols, options, supportedPlatforms, cancellationToken).ConfigureAwait(false);
ConvertAnonymousType\AbstractConvertAnonymousTypeToClassCodeRefactoringProvider.cs (4)
46var (anonymousObject, anonymousType) = await TryGetAnonymousObjectAsync(document, textSpan, cancellationToken).ConfigureAwait(false);
81var (anonymousObject, anonymousType) = await TryGetAnonymousObjectAsync(document, span, cancellationToken).ConfigureAwait(false);
105document, className, isRecord, properties, cancellationToken).ConfigureAwait(false);
297localNameOpt: SyntaxGeneratorExtensions.OtherName, cancellationToken).ConfigureAwait(false);
ConvertTupleToStruct\AbstractConvertTupleToStructCodeRefactoringProvider.cs (17)
65document, textSpan, cancellationToken).ConfigureAwait(false);
238solution, result.Value.DocumentTextChanges, cancellationToken).ConfigureAwait(false);
241resultSolution, result.Value.RenamedToken, cancellationToken).ConfigureAwait(false);
246document, span, scope, isRecord, cancellationToken).ConfigureAwait(false);
266document, span, cancellationToken).ConfigureAwait(false);
295var parameterNamingRule = await document.GetApplicableNamingRuleAsync(SymbolKind.Parameter, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false);
300document, scope, isRecord, structName, capturedTypeParameters, tupleType, parameterNamingRule, cancellationToken).ConfigureAwait(false);
304document, tupleExprOrTypeNode, tupleType, scope, cancellationToken).ConfigureAwait(false);
319document, documentToEditorMap, cancellationToken).ConfigureAwait(false);
341var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
388container, cancellationToken).ConfigureAwait(false);
426document, tupleExprOrTypeNode, cancellationToken).ConfigureAwait(false),
428document.Project, tupleType, cancellationToken).ConfigureAwait(false),
430document.Project, tupleType, cancellationToken).ConfigureAwait(false),
623containerToUpdate, cancellationToken).ConfigureAwait(false);
628containerToUpdate, cancellationToken).ConfigureAwait(false);
825localNameOpt: SyntaxGeneratorExtensions.OtherName, cancellationToken).ConfigureAwait(false);
Copilot\ICopilotChangeAnalysisService.cs (8)
77document, changes, cancellationToken).ConfigureAwait(false);
93var oldText = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
118newDocument, newSpans, cancellationToken).ConfigureAwait(false);
124newDocument, newSpans, cancellationToken).ConfigureAwait(false);
190newDocument, newSpans, diagnosticKind, cancellationToken).ConfigureAwait(false);
228newDocument, span, diagnosticKind, cancellationToken).ConfigureAwait(false);
252var codeFixCollections = await ComputeCodeFixCollectionsAsync().ConfigureAwait(false);
277.ConfigureAwait(false);
DesignerAttribute\DesignerAttributeDiscoveryService.cs (8)
71solutionServices, solutionKey, peReference, cancellationToken).ConfigureAwait(false))
100return await asyncLazy.GetValueAsync(cancellationToken).ConfigureAwait(false);
157var frozenSolution = await solution.WithFrozenPartialCompilationsAsync(cancellationToken).ConfigureAwait(false);
207project, specificDocument, lazyProjectVersion, cancellationToken).ConfigureAwait(false);
251var projectVersion = await lazyProjectVersion.GetValueAsync(cancellationToken).ConfigureAwait(false);
259var data = await ComputeDesignerAttributeDataAsync(project, documentId, filePath, hasDesignerCategoryType.Value, existingInfo.category).ConfigureAwait(false);
273hasDesignerCategoryType, project, documentId, existingCategory, cancellationToken).ConfigureAwait(false);
408await listener.Delay(DelayTimeSpan.NonFocus, cancellationToken).ConfigureAwait(false);
Diagnostics\Service\DocumentAnalysisExecutor.cs (14)
86: await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
88documentAnalyzer, textDocument, kind, _compilationWithAnalyzers?.HostCompilation, tree, cancellationToken).ConfigureAwait(false);
109var isEnabled = await textDocument.Project.HasSuccessfullyLoadedAsync(cancellationToken).ConfigureAwait(false);
123AnalysisKind.Syntax => await GetSyntaxDiagnosticsAsync(analyzer, isCompilerAnalyzer, cancellationToken).ConfigureAwait(false),
124AnalysisKind.Semantic => await GetSemanticDiagnosticsAsync(analyzer, isCompilerAnalyzer, cancellationToken).ConfigureAwait(false),
129diagnostics = await RemapDiagnosticLocationsIfRequiredAsync(textDocument, diagnostics, cancellationToken).ConfigureAwait(false);
159analysisScope, _compilationWithAnalyzers, _logPerformanceInfo, getTelemetryInfo: false, cancellationToken).ConfigureAwait(false);
179var analysisResult = await GetAnalysisResultAsync(analysisScope, cancellationToken).ConfigureAwait(false);
206return await GetCompilerAnalyzerDiagnosticsAsync(analyzer, AnalysisScope.Span, cancellationToken).ConfigureAwait(false);
214var syntaxDiagnostics = await GetAnalysisResultAsync(analysisScope, cancellationToken).ConfigureAwait(false);
241var adjustedSpan = await GetAdjustedSpanForCompilerAnalyzerAsync().ConfigureAwait(false);
242return await GetCompilerAnalyzerDiagnosticsAsync(analyzer, adjustedSpan, cancellationToken).ConfigureAwait(false);
250var semanticDiagnostics = await GetAnalysisResultAsync(analysisScope, cancellationToken).ConfigureAwait(false);
368var diagnostic = await diagnosticData.ToDiagnosticAsync(textDocument.Project, cancellationToken).ConfigureAwait(false);
Diagnostics\Service\EngineV2\DiagnosticIncrementalAnalyzer.Executor.cs (8)
37var result = await ComputeDiagnosticsForAnalyzersAsync(analyzers).ConfigureAwait(false);
42result = await RemoveCompilerSemanticErrorsIfProjectNotLoadedAsync(result).ConfigureAwait(false);
56var projectLoadedSuccessfully = await project.HasSuccessfullyLoadedAsync(cancellationToken).ConfigureAwait(false);
100project, compilationWithAnalyzers, logPerformanceInfo: false, getTelemetryInfo: true, cancellationToken).ConfigureAwait(false);
109return await MergeProjectDiagnosticAnalyzerDiagnosticsAsync(ideAnalyzers, result).ConfigureAwait(false);
132? await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false)
134var syntaxDiagnostics = await DocumentAnalysisExecutor.ComputeDocumentDiagnosticAnalyzerDiagnosticsAsync(documentAnalyzer, textDocument, AnalysisKind.Syntax, compilation, tree, cancellationToken).ConfigureAwait(false);
135var semanticDiagnostics = await DocumentAnalysisExecutor.ComputeDocumentDiagnosticAnalyzerDiagnosticsAsync(documentAnalyzer, textDocument, AnalysisKind.Semantic, compilation, tree, cancellationToken).ConfigureAwait(false);
Diagnostics\Service\EngineV2\DiagnosticIncrementalAnalyzer_GetDiagnostics.cs (5)
65solution.SolutionState, project.State, cancellationToken).ConfigureAwait(false);
67solution.SolutionState, project.State, cancellationToken).ConfigureAwait(false);
70var result = await GetOrComputeDiagnosticAnalysisResultsAsync(analyzers).ConfigureAwait(false);
131project, analyzers, hostAnalyzerInfo, AnalyzerService.CrashOnAnalyzerException, cancellationToken).ConfigureAwait(false);
134compilation, project, [.. analyzers.OfType<DocumentDiagnosticAnalyzer>()], cancellationToken).ConfigureAwait(false);
Diagnostics\Service\EngineV2\DiagnosticIncrementalAnalyzer_GetDiagnosticsForSpan.cs (11)
33var diagnostics = await ComputeDocumentDiagnosticsForAnalyzerCoreAsync(analyzer, executor, cancellationToken).ConfigureAwait(false);
47var diagnostics = await executor.ComputeDiagnosticsAsync(analyzer, cancellationToken).ConfigureAwait(false);
65.ConfigureAwait(false);
68var hostAnalyzerInfo = await _stateManager.GetOrCreateHostAnalyzerInfoAsync(solutionState, project.State, cancellationToken).ConfigureAwait(false);
78document.Project, analyzers, hostAnalyzerInfo, AnalyzerService.CrashOnAnalyzerException, cancellationToken).ConfigureAwait(false);
214if (await TryDeprioritizeAnalyzerAsync(analyzer, kind, span).ConfigureAwait(false))
227var hostAnalyzerInfo = await _stateManager.GetOrCreateHostAnalyzerInfoAsync(solutionState, project.State, cancellationToken).ConfigureAwait(false);
233var version = await GetDiagnosticVersionAsync(document.Project, cancellationToken).ConfigureAwait(false);
244cancellationToken).ConfigureAwait(false);
250diagnosticsMap = await ComputeDocumentDiagnosticsCoreAsync(executor, cancellationToken).ConfigureAwait(false);
287if (!await IsCandidateForDeprioritizationBasedOnRegisteredActionsAsync(analyzer).ConfigureAwait(false))
Diagnostics\Service\EngineV2\DiagnosticIncrementalAnalyzer_IncrementalAnalyzer.cs (5)
48box = new(await ComputeForceAnalyzeProjectAsync().ConfigureAwait(false));
79var allAnalyzers = await _stateManager.GetOrCreateAnalyzersAsync(solutionState, projectState, cancellationToken).ConfigureAwait(false);
80var hostAnalyzerInfo = await _stateManager.GetOrCreateHostAnalyzerInfoAsync(solutionState, projectState, cancellationToken).ConfigureAwait(false);
88project, fullSolutionAnalysisAnalyzers, hostAnalyzerInfo, AnalyzerService.CrashOnAnalyzerException, cancellationToken).ConfigureAwait(false);
91compilationWithAnalyzers, project, [.. fullSolutionAnalysisAnalyzers.OfType<DocumentDiagnosticAnalyzer>()], cancellationToken).ConfigureAwait(false);
DocumentHighlighting\AbstractDocumentHighlightsService.cs (8)
60document, position, documentsToSearch, options, cancellationToken).ConfigureAwait(false);
76semanticModel, position, solution.Services, cancellationToken).ConfigureAwait(false);
82symbol, document, documentsToSearch, cancellationToken).ConfigureAwait(false);
131symbol, options, cancellationToken).ConfigureAwait(false);
186additionalReferences.AddRange(await GetAdditionalReferencesAsync(currentDocument, symbol, cancellationToken).ConfigureAwait(false));
192documentsToSearch, cancellationToken).ConfigureAwait(false);
291var span = await GetLocationSpanAsync(solution, location, cancellationToken).ConfigureAwait(false);
314var root = await tree.GetRootAsync(cancellationToken).ConfigureAwait(false);
EditAndContinue\EditSession.cs (11)
133var capabilities = await Capabilities.GetValueAsync(cancellationToken).ConfigureAwait(false);
560var (oldDocument, oldDocumentState) = await DebuggingSession.LastCommittedSolution.GetDocumentAndStateAsync(newDocument, cancellationToken, reloadOutOfSyncDocument: true).ConfigureAwait(false);
932var (mvid, mvidReadError) = await DebuggingSession.GetProjectModuleIdAsync(newProject, cancellationToken).ConfigureAwait(false);
967await AnalyzeDocumentsAsync(solution, documentDifferences, solutionActiveStatementSpanProvider, projectDiagnostics, cancellationToken).ConfigureAwait(false);
1012var moduleBlockingDiagnosticId = await ReportModuleDiagnosticsAsync(mvid, oldProject, newProject, changedDocumentAnalyses, projectDiagnostics, cancellationToken).ConfigureAwait(false);
1039var oldCompilation = await oldProject.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
1055var newCompilation = await newProject.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
1060var oldActiveStatementsMap = await BaseActiveStatements.GetValueAsync(cancellationToken).ConfigureAwait(false);
1071var capabilities = await Capabilities.GetValueAsync(cancellationToken).ConfigureAwait(false);
1133var unsupportedChangesDiagnostic = await GetUnsupportedChangesDiagnosticAsync(emitResult, cancellationToken).ConfigureAwait(false);
1227Telemetry.LogRuntimeCapabilities(await Capabilities.GetValueAsync(cancellationToken).ConfigureAwait(false));
EncapsulateField\AbstractEncapsulateFieldService.cs (14)
47var fields = await GetFieldsAsync(document, span, cancellationToken).ConfigureAwait(false);
60var fields = await GetFieldsAsync(document, span, cancellationToken).ConfigureAwait(false);
133solution, result.Value, cancellationToken).ConfigureAwait(false);
138document, fields, updateReferences, cancellationToken).ConfigureAwait(false);
157var nextSolution = await EncapsulateFieldAsync(document, currentField, updateReferences, cancellationToken).ConfigureAwait(false);
194updateReferences, solution, document, field, finalFieldName, generatedPropertyName, cancellationToken).ConfigureAwait(false);
198var rewrittenFieldDeclaration = await RewriteFieldNameAndAccessibilityAsync(finalFieldName, markFieldPrivate, document, declarationAnnotation, cancellationToken).ConfigureAwait(false);
202document = await Formatter.FormatAsync(document.WithSyntaxRoot(rewrittenFieldDeclaration), Formatter.Annotation, formattingOptions, cancellationToken).ConfigureAwait(false);
222document, document.Project.Solution, field, generatedProperty, cancellationToken).ConfigureAwait(false);
224documentWithProperty = await Formatter.FormatAsync(documentWithProperty, Formatter.Annotation, formattingOptions, cancellationToken).ConfigureAwait(false);
225documentWithProperty = await Simplifier.ReduceAsync(documentWithProperty, simplifierOptions, cancellationToken).ConfigureAwait(false);
250cancellationToken).ConfigureAwait(false);
263cancellationToken).ConfigureAwait(false);
271cancellationToken).ConfigureAwait(false);
ExternalAccess\VSTypeScript\Api\VSTypeScriptDocumentNavigationServiceWrapper.cs (4)
35workspace, documentId, position, virtualSpace, allowInvalidPosition: false, cancellationToken).ConfigureAwait(false);
37await location.NavigateToAsync(NavigationOptions.Default, cancellationToken).ConfigureAwait(false);
47workspace, documentId, position, virtualSpace, allowInvalidPosition: false, cancellationToken).ConfigureAwait(false);
49await location.NavigateToAsync(NavigationOptions.Default, cancellationToken).ConfigureAwait(false);
ExtractInterface\AbstractExtractInterfaceService.cs (18)
50var typeAnalysisResult = await AnalyzeTypeAtPositionAsync(document, span.Start, TypeDiscoveryRule.TypeNameOnly, cancellationToken).ConfigureAwait(false);
67cancellationToken).ConfigureAwait(false);
75return await ExtractInterfaceFromAnalyzedTypeAsync(typeAnalysisResult, cancellationToken).ConfigureAwait(false);
84var typeNode = await GetTypeDeclarationAsync(document, position, typeDiscoveryRule, cancellationToken).ConfigureAwait(false);
130return await ExtractInterfaceFromAnalyzedTypeAsync(refactoringResult, extractInterfaceOptions, cancellationToken).ConfigureAwait(false);
159cancellationToken).ConfigureAwait(false);
167cancellationToken).ConfigureAwait(false);
182cancellationToken).ConfigureAwait(false);
192cancellationToken).ConfigureAwait(false);
202cancellationToken).ConfigureAwait(false);
207cancellationToken).ConfigureAwait(false);
224cancellationToken).ConfigureAwait(false);
232cancellationToken).ConfigureAwait(false);
241extractInterfaceOptions.IncludedMembers, symbolMapping.SymbolToDeclarationAnnotationMap, cancellationToken).ConfigureAwait(false);
246cancellationToken).ConfigureAwait(false);
293cancellationToken).ConfigureAwait(false);
299cancellationToken).ConfigureAwait(false);
359cancellationToken).ConfigureAwait(false);
ExtractMethod\MethodExtractor.cs (6)
73OriginalSelectionResult, analyzeResult, insertionPointNode, cancellationToken).ConfigureAwait(false);
75var triviaResult = await PreserveTriviaAsync(analyzedDocument.Root, cancellationToken).ConfigureAwait(false);
81var generatedCode = await generator.GenerateAsync(cancellationToken).ConfigureAwait(false);
99documentWithoutFinalFormatting, invocationNameToken, methodDefinition, cancellationToken).ConfigureAwait(false);
103documentWithoutFinalFormatting, invocationNameToken, cancellationToken).ConfigureAwait(false);
151var simplifiedDocument = await Simplifier.ReduceAsync(annotatedDocument, Simplifier.Annotation, this.Options.CodeCleanupOptions.SimplifierOptions, cancellationToken).ConfigureAwait(false);
FindUsages\AbstractFindUsagesService_FindImplementations.cs (9)
29document, position, cancellationToken).ConfigureAwait(false);
77var implementations = await FindSourceImplementationsAsync(solution, symbol, cancellationToken).ConfigureAwait(false);
102symbol, solution, cancellationToken).ConfigureAwait(false);
115solution, linkedSymbol, cancellationToken).ConfigureAwait(false);
144var implementations = await FindSourceAndMetadataImplementationsAsync(solution, symbol, cancellationToken).ConfigureAwait(false);
175symbol, solution, cancellationToken: cancellationToken).ConfigureAwait(false);
191implementation, solution, cancellationToken: cancellationToken).ConfigureAwait(false);
201namedType, solution, transitive: true, cancellationToken: cancellationToken).ConfigureAwait(false));
206symbol, solution, cancellationToken: cancellationToken).ConfigureAwait(false);
FindUsages\AbstractFindUsagesService_FindReferences.cs (4)
31document.Project.Solution, definitionTrackingContext.GetDefinitions(), cancellationToken).ConfigureAwait(false);
54context, document, position, classificationOptions, cancellationToken).ConfigureAwait(false);
76var thirdParty = await provider.GetThirdPartyDefinitionItemAsync(solution, definition, cancellationToken).ConfigureAwait(false);
90document, position, cancellationToken).ConfigureAwait(false);
FullyQualify\AbstractFullyQualifyService.cs (7)
56return await GetFixDataInCurrentProcessAsync(document, span, cancellationToken).ConfigureAwait(false);
78var matchingTypes = await FindAsync(name, ignoreCase, SymbolFilter.Type).ConfigureAwait(false);
79var matchingAttributeTypes = inAttributeContext ? await FindAsync(name + nameof(Attribute), ignoreCase, SymbolFilter.Type).ConfigureAwait(false) : [];
80var matchingNamespaces = inAttributeContext ? [] : await FindAsync(name, ignoreCase, SymbolFilter.Namespace).ConfigureAwait(false);
116project, query, filter, cancellationToken).ConfigureAwait(false);
213var textChanges = await ProcessNodeAsync(document, simpleName, containerName, symbolResult.OriginalSymbol, cancellationToken).ConfigureAwait(false);
220var newRoot = await ReplaceNodeAsync(simpleName, containerName, originalSymbol.IsType, cancellationToken).ConfigureAwait(false);
GenerateConstructors\AbstractGenerateConstructorsCodeRefactoringProvider.cs (7)
103priorDocument, action, CodeAnalysisProgress.None, cancellationToken).ConfigureAwait(false);
113priorDocument.Project.Solution, codeAction, progressTracker, cancellationToken).ConfigureAwait(false);
146return await action.GetOperationsAsync(originalSolution, progressTracker, cancellationToken).ConfigureAwait(false);
168document, textSpan, addNullChecks: false, desiredAccessibility, cancellationToken).ConfigureAwait(false);
177var nonSelectionAction = await HandleNonSelectionAsync(document, textSpan, desiredAccessibility, cancellationToken).ConfigureAwait(false);
270var info = await GetSelectedMemberInfoAsync(document, textSpan, allowPartialSelection: true, cancellationToken).ConfigureAwait(false);
273var state = await State.TryGenerateAsync(this, document, textSpan, info.ContainingType, desiredAccessibility, info.SelectedMembers, cancellationToken).ConfigureAwait(false);
GenerateEqualsAndGetHashCodeFromMembers\GenerateEqualsAndGetHashCodeFromMembersCodeRefactoringProvider.cs (4)
61var actions = await GenerateEqualsAndGetHashCodeFromMembersAsync(document, textSpan, cancellationToken).ConfigureAwait(false);
118hasEquals, hasGetHashCode, withDialog: true, globalOptions, cancellationToken).ConfigureAwait(false);
176var info = await GetSelectedMemberInfoAsync(document, textSpan, allowPartialSelection: false, cancellationToken).ConfigureAwait(false);
192hasEquals, hasGetHashCode, withDialog: false, globalOptions: null, cancellationToken).ConfigureAwait(false);
InheritanceMargin\AbstractInheritanceMarginService_Helpers.cs (11)
107var mappingResult = await mappingService.MapSymbolAsync(document, member, cancellationToken).ConfigureAwait(false);
142result.AddRange(await GetGlobalImportsItemsAsync(document, spanToSearch, frozenPartialSemantics, cancellationToken).ConfigureAwait(false));
306cancellationToken).ConfigureAwait(false);
351var allImplementingSymbols = await GetImplementingSymbolsForTypeMemberAsync(solution, memberSymbol, cancellationToken).ConfigureAwait(false);
372var allOverridingSymbols = await SymbolFinder.FindOverridesArrayAsync(memberSymbol, solution, cancellationToken: cancellationToken).ConfigureAwait(false);
562var symbolInSource = await SymbolFinder.FindSourceDefinitionAsync(targetSymbol, solution, cancellationToken).ConfigureAwait(false);
637cancellationToken: cancellationToken).ConfigureAwait(false);
647builder.AddRange(await SymbolFinder.FindOverridesArrayAsync(implementationSymbol, solution, cancellationToken: cancellationToken).ConfigureAwait(false));
689cancellationToken: cancellationToken).ConfigureAwait(false);
694cancellationToken: cancellationToken).ConfigureAwait(false);
703cancellationToken: cancellationToken).ConfigureAwait(false);
InitializeParameter\AbstractAddParameterCheckCodeRefactoringProvider.cs (6)
211document = await AddStringCheckAsync(document, parameter, functionDeclaration, (IMethodSymbol)parameter.ContainingSymbol, blockStatement, NullOrEmptySuffix, lazySimplifierOptions, cancellationToken).ConfigureAwait(false);
217(IMethodSymbol)parameter.ContainingSymbol, blockStatement, lazySimplifierOptions, cancellationToken).ConfigureAwait(false);
552document, parameter, blockStatement, options, cancellationToken).ConfigureAwait(false);
561cancellationToken).ConfigureAwait(false);
577cancellationToken).ConfigureAwait(false);
593cancellationToken).ConfigureAwait(false);
InitializeParameter\AbstractInitializeMemberFromParameterCodeRefactoringProviderMemberCreation.cs (5)
83var rules = await document.GetNamingRulesAsync(cancellationToken).ConfigureAwait(false);
89document, parameter, blockStatement, rules, parameterNameParts.BaseNameParts, cancellationToken).ConfigureAwait(false);
99method, blockStatement, rules, cancellationToken).ConfigureAwait(false);
414cancellationToken).ConfigureAwait(false);
431document, constructorDeclaration, blockStatement, parameter, fieldOrProperty, cancellationToken).ConfigureAwait(false);
IntroduceParameter\AbstractIntroduceParameterCodeRefactoringProvider.cs (4)
96var actions = await GetActionsAsync(document, expression, methodSymbol, containingMethod, cancellationToken).ConfigureAwait(false);
150document, expression, cancellationToken).ConfigureAwait(false);
157var methodCallSites = await FindCallSitesAsync(document, methodSymbol, cancellationToken).ConfigureAwait(false);
282documents: null, FindReferencesSearchOptions.Default, cancellationToken).ConfigureAwait(false);
IntroduceParameter\IntroduceParameterDocumentRewriter.cs (15)
50compilation, document, invocations, insertionIndex, cancellationToken).ConfigureAwait(false);
55compilation, document, insertionIndex, invocations, cancellationToken).ConfigureAwait(false);
225var parameterName = await GetNewParameterNameAsync(cancellationToken).ConfigureAwait(false);
226var expressionParameterMap = await MapExpressionToParametersAsync(cancellationToken).ConfigureAwait(false);
261? await ExtractMethodAsync(validParameters, newMethodIdentifier, _generator, cancellationToken).ConfigureAwait(false)
262: await GenerateNewMethodOverloadAsync(insertionIndex, _generator, cancellationToken).ConfigureAwait(false);
266var parameterType = await GetTypeOfExpressionAsync(cancellationToken).ConfigureAwait(false);
392var typeSymbol = await GetTypeOfExpressionAsync(cancellationToken).ConfigureAwait(false);
394validParameters, newMethodIdentifier, typeSymbol, isTrampoline: true, cancellationToken).ConfigureAwait(false);
437validParameters: null, newMethodIdentifier: null, typeSymbol: null, isTrampoline: false, cancellationToken).ConfigureAwait(false);
488var expressionToParameterMap = await MapExpressionToParametersAsync(cancellationToken).ConfigureAwait(false);
489var parameterName = await GetNewParameterNameAsync(cancellationToken).ConfigureAwait(false);
527var parameterType = await GetTypeOfExpressionAsync(cancellationToken).ConfigureAwait(false);
632var matches = await FindMatchesAsync(cancellationToken).ConfigureAwait(false);
633var parameterName = await GetNewParameterNameAsync(cancellationToken).ConfigureAwait(false);
IntroduceUsingStatement\AbstractIntroduceUsingStatementCodeRefactoringProvider.cs (2)
200document, declarationStatement, statementsToSurround, usingStatement, surroundingStatements, declarationStatementIndex, cancellationToken).ConfigureAwait(false);
235document, expressionStatement, statementsToSurround, usingStatement, surroundingStatements, statementIndex, cancellationToken).ConfigureAwait(false);
MetadataAsSource\DecompilationMetadataAsSourceFileProvider.cs (6)
105var infoKey = await GetUniqueDocumentKeyAsync(sourceProject, topLevelNamedType, signaturesOnly: !useDecompiler, cancellationToken).ConfigureAwait(false);
207navigateLocation = await MetadataAsSourceHelpers.GetLocationInGeneratedSourceAsync(symbolId, temporaryDocument, cancellationToken).ConfigureAwait(false);
211navigateLocation ??= await RelocateSymbol_NoLockAsync(metadataSolution, fileInfo, symbolId, cancellationToken).ConfigureAwait(false);
261return await MetadataAsSourceHelpers.GetLocationInGeneratedSourceAsync(symbolId, document, cancellationToken).ConfigureAwait(false);
268return await MetadataAsSourceHelpers.GetLocationInGeneratedSourceAsync(symbolId, temporaryDocument, cancellationToken).ConfigureAwait(false);
368var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
MoveStaticMembers\MoveStaticMembersWithDialogCodeAction.cs (11)
77cancellationToken).ConfigureAwait(false);
110cancellationToken).ConfigureAwait(false);
118var memberReferenceLocations = await FindMemberReferencesAsync(newDoc.Project.Solution, newDoc.Project.Id, moveOptions.SelectedMembers, cancellationToken).ConfigureAwait(false);
120var solutionWithFixedReferences = await RefactorReferencesAsync(projectToLocations, newDoc.Project.Solution, newType, typeArgIndices, cancellationToken).ConfigureAwait(false);
133var movedSolution = await MembersPuller.PullMembersUpAsync(sourceDoc, pullMembersUpOptions, cancellationToken).ConfigureAwait(false);
193oldSolution, sourceDocId.ProjectId, selectedMembers, cancellationToken).ConfigureAwait(false);
195var solutionWithFixedReferences = await RefactorReferencesAsync(projectToLocations, oldSolution, newType, typeArgIndices, cancellationToken).ConfigureAwait(false);
213return await MembersPuller.PullMembersUpAsync(sourceDoc, pullMembersUpOptions, cancellationToken).ConfigureAwait(false);
239cancellationToken).ConfigureAwait(false);
266var docEditor = await DocumentEditor.CreateAsync(doc, cancellationToken).ConfigureAwait(false);
362: await SymbolFinder.FindReferencesAsync(resolvedMember, solution, cancellationToken).ConfigureAwait(false);
MoveToNamespace\AbstractMoveToNamespaceService.cs (9)
54var typeAnalysisResult = await AnalyzeTypeAtPositionAsync(document, span.Start, cancellationToken).ConfigureAwait(false);
77var moveToNamespaceAnalysisResult = await TryAnalyzeNamespaceAsync(document, node, position, cancellationToken).ConfigureAwait(false);
84moveToNamespaceAnalysisResult = await TryAnalyzeNamedTypeAsync(document, node, cancellationToken).ConfigureAwait(false);
103var namespaces = await GetNamespacesAsync(document, cancellationToken).ConfigureAwait(false);
154var namespaces = await GetNamespacesAsync(document, cancellationToken).ConfigureAwait(false);
220var memberSymbols = await GetMemberSymbolsAsync(document, container, cancellationToken).ConfigureAwait(false);
259var mergedSolution = await PropagateChangeToLinkedDocumentsAsync(modifiedDocument, formattingOptions, cancellationToken).ConfigureAwait(false);
272cancellationToken).ConfigureAwait(false);
278var formattedDocument = await Formatter.FormatAsync(document, SyntaxAnnotation.ElasticAnnotation, formattingOptions, cancellationToken).ConfigureAwait(false);
QuickInfo\CommonSemanticQuickInfoProvider.cs (5)
26var (tokenInformation, supportedPlatforms) = await ComputeQuickInfoDataAsync(context, token).ConfigureAwait(false);
33var onTheFlyDocsInfo = await GetOnTheFlyDocsInfoAsync(context, cancellationToken).ConfigureAwait(false);
35services, semanticModel, token, tokenInformation, supportedPlatforms, context.Options, onTheFlyDocsInfo, cancellationToken).ConfigureAwait(false);
47context.Services, context.SemanticModel, token, tokenInformation, supportedPlatforms: null, context.Options, onTheFlyDocsInfo: null, context.CancellationToken).ConfigureAwait(false);
59return await ComputeFromLinkedDocumentsAsync(context, token, linkedDocumentIds).ConfigureAwait(false);
ReplaceMethodWithProperty\ReplaceMethodWithPropertyCodeRefactoringProvider.cs (15)
159var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
164getMethod, originalSolution, cancellationToken).ConfigureAwait(false);
168setMethod, originalSolution, cancellationToken).ConfigureAwait(false);
182updatedSolution = await UpdateReferencesAsync(updatedSolution, propertyName, nameChanged, getReferencesByDocument, setReferencesByDocument, cancellationToken).ConfigureAwait(false);
183updatedSolution = await ReplaceGetMethodsAndRemoveSetMethodsAsync(originalSolution, updatedSolution, propertyName, nameChanged, getMethodReferences, setMethodReferences, updateSetMethod: setMethod != null, cancellationToken).ConfigureAwait(false);
199cancellationToken).ConfigureAwait(false);
321var getDefinitionsByDocumentId = await GetDefinitionsByDocumentIdAsync(originalSolution, getMethodReferences, cancellationToken).ConfigureAwait(false);
322var setDefinitionsByDocumentId = await GetDefinitionsByDocumentIdAsync(originalSolution, setMethodReferences, cancellationToken).ConfigureAwait(false);
333propertyName, nameChanged, updatedSolution, documentId, getDefinitions, setDefinitions, updateSetMethod, cancellationToken).ConfigureAwait(false);
356updatedSolution, compilation, documentId, originalGetDefinitions, updateSetMethod, cancellationToken).ConfigureAwait(false);
385var setMethodDeclaration = await GetMethodDeclarationAsync(setMethod, cancellationToken).ConfigureAwait(false);
414var getMethodDeclaration = await GetMethodDeclarationAsync(getMethod, cancellationToken).ConfigureAwait(false);
415var setMethodDeclaration = await GetMethodDeclarationAsync(setMethod, cancellationToken).ConfigureAwait(false);
442return await reference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
458var syntax = await definition.DeclaringSyntaxReferences[0].GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
ReplacePropertyWithMethods\ReplacePropertyWithMethodsCodeRefactoringProvider.cs (11)
82var semanticModel = await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
85var propertyReferences = await SymbolFinder.FindReferencesAsync(propertySymbol, originalSolution, cancellationToken).ConfigureAwait(false);
106desiredGetMethodName, desiredSetMethodName, cancellationToken).ConfigureAwait(false);
110desiredGetMethodName, desiredSetMethodName, cancellationToken).ConfigureAwait(false);
204desiredGetMethodName, desiredSetMethodName, cancellationToken).ConfigureAwait(false);
297var definitionsByDocumentId = await GetDefinitionsByDocumentIdAsync(originalSolution, references, cancellationToken).ConfigureAwait(false);
305desiredGetMethodName, desiredSetMethodName, cancellationToken).ConfigureAwait(false);
324var syntax = await definition.DeclaringSyntaxReferences[0].GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
353updatedSolution, semanticModel.Compilation, documentId, originalDefinitions, cancellationToken).ConfigureAwait(false);
402var declaration = await GetPropertyDeclarationAsync(property, cancellationToken).ConfigureAwait(false);
419return await reference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
Snippets\SnippetFunctionService.cs (6)
48var simplifiedTypeName = await GetSimplifiedTypeNameAtSpanAsync(documentWithFullyQualifiedTypeName, updatedTextSpan, simplifierOptions, cancellationToken).ConfigureAwait(false);
58var typeSymbol = await GetEnumSymbolAsync(document, switchExpressionLocation, cancellationToken).ConfigureAwait(false);
72var simplifiedTypeName = await GetSimplifiedEnumNameAsync(document, fullyQualifiedEnumName, enumFields.First().Name, caseGenerationLocation, simplifierOptions, cancellationToken).ConfigureAwait(false);
133var (documentWithFullyQualified, fullyQualifiedTypeLocation) = await GetDocumentWithEnumCaseAsync(document, fullyQualifiedTypeName, firstEnumMemberName, caseGenerationLocation, cancellationToken).ConfigureAwait(false);
136var simplifiedEnum = await GetSimplifiedTypeNameAtSpanAsync(documentWithFullyQualified, fullyQualifiedTypeLocation, simplifierOptions, cancellationToken).ConfigureAwait(false);
155var simplifiedDocument = await Simplifier.ReduceAsync(documentWithAnnotations, simplifierOptions, cancellationToken).ConfigureAwait(false);
Snippets\SnippetProviders\AbstractSnippetProvider.cs (12)
75var textChanges = await GenerateSnippetTextChangesAsync(document, position, cancellationToken).ConfigureAwait(false);
78var snippetDocument = await GetDocumentWithSnippetAsync(document, textChanges, cancellationToken).ConfigureAwait(false);
82var snippetWithTriviaDocument = await GetDocumentWithSnippetAndTriviaAsync(snippetDocument, position, syntaxFacts, cancellationToken).ConfigureAwait(false);
85var formatAnnotatedSnippetDocument = await AddFormatAnnotationAsync(snippetWithTriviaDocument, position, cancellationToken).ConfigureAwait(false);
88var reformattedDocument = await CleanupDocumentAsync(formatAnnotatedSnippetDocument, cancellationToken).ConfigureAwait(false);
91var documentWithIndentation = await AddIndentationToDocumentAsync(reformattedDocument, cancellationToken).ConfigureAwait(false);
149document, FindSnippetAnnotation, addImportPlacementOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
151document = await Simplifier.ReduceAsync(document, FindSnippetAnnotation, simplifierOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
154document = await Formatter.FormatAsync(document, FindSnippetAnnotation, syntaxFormattingOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
157document = await Formatter.FormatAsync(document, SyntaxAnnotation.ElasticAnnotation, syntaxFormattingOptions, cancellationToken: cancellationToken).ConfigureAwait(false);
200var annotatedSnippetRoot = await AnnotateNodesToReformatAsync(document, position, cancellationToken).ConfigureAwait(false);
235return await AddIndentationToDocumentAsync(document, snippet, cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\Analyzers\RemoveUnnecessarySuppressions\AbstractRemoveUnnecessaryPragmaSuppressionsDiagnosticAnalyzer.cs (6)
169idToSuppressMessageAttributesMap, suppressMessageAttributesToIsUsedMap, userIdExclusions, userCategoryExclusions, cancellationToken).ConfigureAwait(false);
187getSupportedDiagnostics, compilerDiagnosticIds, cancellationToken).ConfigureAwait(false);
464var analysisResult = await compilationWithAnalyzers.GetAnalysisResultAsync(semanticModel.SyntaxTree, analyzers, cancellationToken).ConfigureAwait(false);
471analysisResult = await compilationWithAnalyzers.GetAnalysisResultAsync(semanticModel, filterSpan: null, analyzers, cancellationToken).ConfigureAwait(false);
596var attributeNode = await attribute.ApplicationSyntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
819var attributeNode = await attribute.ApplicationSyntaxReference.GetSyntaxAsync(cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateConstructor\AbstractGenerateConstructorService.State.cs (10)
71var parameterNamingRule = await document.Document.GetApplicableNamingRuleAsync(SymbolKind.Parameter, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false);
74if (!await state.TryInitializeAsync(node, cancellationToken).ConfigureAwait(false))
115if (!await TryInitializeDelegatedConstructorAsync(cancellationToken).ConfigureAwait(false))
131_document, this.TypeToGenerateIn, _arguments, ParameterTypes, parameterNames, cancellationToken).ConfigureAwait(false);
175_document, this.TypeToGenerateIn, remainingArguments, remainingParameterTypes, remainingParameterNames, cancellationToken).ConfigureAwait(false);
415return await GenerateThisOrBaseDelegatingConstructorAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false) ??
416await GenerateMemberDelegatingConstructorAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false);
427var (members, assignments) = await GenerateMembersAndAssignmentsAsync(document, withFields, withProperties, cancellationToken).ConfigureAwait(false);
452cancellationToken).ConfigureAwait(false);
507cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateParameterizedMember\TypeParameterSubstitution.cs (4)
92(INamedTypeSymbol)symbol.ConstraintTypes[0], projects).ConfigureAwait(false);
97(INamedTypeSymbol)symbol.ConstraintTypes[i], projects).ConfigureAwait(false);
130symbol, solution, transitive: true, projects, _cancellationToken).ConfigureAwait(false);
133symbol, solution, transitive: true, projects, _cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\GenerateVariable\AbstractGenerateVariableService.cs (4)
100document.Document, state, SymbolKind.Property, state.DetermineMaximalAccessibility(), cancellationToken).ConfigureAwait(false))
122var namingStyle = await document.GetApplicableNamingRuleAsync(kind, accessibility, cancellationToken).ConfigureAwait(false);
182document, state, SymbolKind.Local, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false))
198document, state, SymbolKind.Parameter, Accessibility.NotApplicable, cancellationToken).ConfigureAwait(false))
src\Analyzers\Core\CodeFixes\MakeMethodAsynchronous\AbstractMakeMethodAsynchronousCodeFixProvider.cs (4)
121? await RenameThenAddAsyncTokenAsync(keepVoid, document, node, methodSymbol, knownTypes, cancellationToken).ConfigureAwait(false)
122: await AddAsyncTokenAsync(keepVoid, document, methodSymbol, knownTypes, node, cancellationToken).ConfigureAwait(false);
169var newSolution = await Renamer.RenameSymbolAsync(solution, methodSymbol, new SymbolRenameOptions(), newName, cancellationToken).ConfigureAwait(false);
177return await AddAsyncTokenAsync(keepVoid, newDocument, newMethod, knownTypes, newNode, cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\MakeMethodSynchronous\AbstractMakeMethodSynchronousCodeFixProvider.cs (8)
65return await RenameThenRemoveAsyncTokenAsync(document, node, methodSymbol, cancellationToken).ConfigureAwait(false);
69return await RemoveAsyncTokenAsync(document, methodSymbol, node, cancellationToken).ConfigureAwait(false);
83var newSolution = await Renamer.RenameSymbolAsync(solution, methodSymbol, new SymbolRenameOptions(), newName, cancellationToken).ConfigureAwait(false);
90return await RemoveAsyncTokenAsync(newDocument, newMethod, newNode, cancellationToken).ConfigureAwait(false);
116newDocument, annotation, cancellationToken).ConfigureAwait(false);
138[methodSymbol], document.Project.Solution, cancellationToken).ConfigureAwait(false);
146document.Project.Solution, [.. referencedSymbol.Locations], cancellationToken).ConfigureAwait(false);
164currentSolution, group, cancellationToken).ConfigureAwait(false);
src\Analyzers\Core\CodeFixes\RemoveUnusedParametersAndValues\AbstractRemoveUnusedValuesCodeFixProvider.cs (10)
287var preprocessedDocument = await PreprocessDocumentAsync(document, diagnostics, cancellationToken).ConfigureAwait(false);
288var newRoot = await GetNewRootAsync(preprocessedDocument, formattingOptions, diagnostics, cancellationToken).ConfigureAwait(false);
336diagnosticId, preference, cancellationToken).ConfigureAwait(false);
638!(await IsLocalDeclarationWithNoReferencesAsync(localDeclarationStatement, document, cancellationToken).ConfigureAwait(false)))
759ReplaceDiscardDeclarationsWithAssignmentsAsync, currentRoot, document, options, cancellationToken).ConfigureAwait(false);
767AdjustLocalDeclarationsAsync, currentRoot, document, options, cancellationToken).ConfigureAwait(false);
789var newMemberDecl = await processMemberDeclarationAsync(memberDecl, newDocument, options, cancellationToken).ConfigureAwait(false);
861if (await TryRemoveUnusedLocalAsync(declStatement, originalDeclStatement).ConfigureAwait(false))
901if (await IsLocalDeclarationWithNoReferencesAsync(newDecl, document, cancellationToken).ConfigureAwait(false))
924var referencedSymbols = await SymbolFinder.FindReferencesAsync(local, document.Project.Solution, cancellationToken).ConfigureAwait(false);
StackTraceExplorer\StackTraceExplorerUtilities.cs (4)
60cancellationToken).ConfigureAwait(false);
64var method = await TryGetBestMatchAsync(project, fullyQualifiedTypeName, methodNode, methodArguments, methodTypeArguments, cancellationToken).ConfigureAwait(false);
82var method = await TryGetBestMatchAsync(project, fullyQualifiedTypeName, methodNode, methodArguments, methodTypeArguments, cancellationToken).ConfigureAwait(false);
123var matchingMethod = await resolver.TryGetBestMatchAsync(project, type, methodNode, methodArguments, methodTypeArguments, cancellationToken).ConfigureAwait(false);
SymbolSearch\Windows\SymbolSearchUpdateEngine.Update.cs (15)
121var delayUntilNextUpdate = await UpdateDatabaseInBackgroundWorkerAsync(cancellationToken).ConfigureAwait(false);
188return await PatchLocalDatabaseAsync(databaseFileInfo, cancellationToken).ConfigureAwait(false);
193return await DownloadFullDatabaseAsync(databaseFileInfo, cancellationToken).ConfigureAwait(false);
229var (_, delay) = await DownloadFullDatabaseWorkerAsync(databaseFileInfo, cancellationToken).ConfigureAwait(false);
242var element = await DownloadFileAsync(serverPath, cancellationToken).ConfigureAwait(false);
243var result = await ProcessFullDatabaseXElementAsync(databaseFileInfo, element, cancellationToken).ConfigureAwait(false);
255var (succeeded, contentBytes) = await TryParseDatabaseElementAsync(element, cancellationToken).ConfigureAwait(false);
410return await DownloadFullDatabaseAsync(databaseFileInfo, cancellationToken).ConfigureAwait(false);
422var element = await DownloadFileAsync(serverPath, cancellationToken).ConfigureAwait(false);
428cancellationToken).ConfigureAwait(false);
472var delayUntilUpdate = await TryProcessPatchXElementAsync(databaseFileInfo, patchElement, getDatabaseBytes, cancellationToken).ConfigureAwait(false);
487return await DownloadFullDatabaseAsync(databaseFileInfo, cancellationToken).ConfigureAwait(false);
596var (element, delay) = await TryDownloadFileAsync(client, cancellationToken).ConfigureAwait(false);
615using var stream = await fileDownloader.ReadFileAsync().ConfigureAwait(false);
697var contentBytes = await Updater.ConvertContentAttributeAsync(contentsAttribute, cancellationToken).ConfigureAwait(false);
SyncNamespaces\AbstractSyncNamespacesService.cs (9)
42var diagnosticsByProject = await GetDiagnosticsByProjectAsync(projects, diagnosticAnalyzers, IsHostAnalyzer, cancellationToken).ConfigureAwait(false);
51solution, CodeFixProvider, diagnosticsByProject, progressTracker, cancellationToken).ConfigureAwait(false);
55return await ApplyCodeFixAsync(fixAllProvider, fixAllContext, cancellationToken).ConfigureAwait(false);
68var diagnostics = await GetDiagnosticsAsync(project, diagnosticAnalyzers, isHostAnalyzer, cancellationToken).ConfigureAwait(false);
81var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
92return await analyzerCompilation.GetAnalyzerDiagnosticsAsync(cancellationToken).ConfigureAwait(false);
141var fixAllAction = await fixAllProvider.GetFixAsync(fixAllContext).ConfigureAwait(false);
145fixAllContext.Solution, fixAllContext.Progress, cancellationToken).ConfigureAwait(false);
170var projectDiagnostics = await GetProjectDiagnosticsAsync(document.Project, cancellationToken).ConfigureAwait(false);
UseAutoProperty\AbstractUseAutoPropertyCodeFixProvider.cs (8)
94return await ProcessResultWorkerAsync(originalSolution, currentSolution, diagnostic, cancellationToken).ConfigureAwait(false);
106diagnostic, originalSolution, currentSolution, cancellationToken).ConfigureAwait(false);
148cancellationToken).ConfigureAwait(false);
264var finalFieldRoot = await FormatAsync(updatedFieldDocument, updatedProperty, cancellationToken).ConfigureAwait(false);
281newFieldTreeRoot = await FormatAsync(updatedFieldDocument, updatedProperty, cancellationToken).ConfigureAwait(false);
282newPropertyTreeRoot = await FormatAsync(updatedPropertyDocument, updatedProperty, cancellationToken).ConfigureAwait(false);
382document, SpecializedFormattingAnnotation, options, formattingRules, cancellationToken).ConfigureAwait(false);
387document, codeCleanupOptions, cancellationToken).ConfigureAwait(false);
ValueTracking\ValueTracker.cs (7)
25var (symbol, node) = await GetSelectedSymbolAsync(selection, document, cancellationToken).ConfigureAwait(false);
49await progressCollector.TryReportAsync(solution, location, symbol, cancellationToken).ConfigureAwait(false);
68await progressCollector.TryReportAsync(document.Project.Solution, node.GetLocation(), symbol, cancellationToken).ConfigureAwait(false);
81var symbol = await GetSymbolAsync(previousTrackedItem, solution, cancellationToken).ConfigureAwait(false);
98var previousSymbol = await GetSymbolAsync(previousTrackedItem.Parent, solution, cancellationToken).ConfigureAwait(false);
171documents: null, FindReferencesSearchOptions.Default, cancellationToken).ConfigureAwait(false);
185documents: null, FindReferencesSearchOptions.Default, cancellationToken).ConfigureAwait(false);
Wrapping\AbstractCodeActionComputer.cs (5)
124var (root, rewrittenRoot, spanToFormat) = await RewriteTreeAsync(edits, cancellationToken).ConfigureAwait(false);
133var formattedDocument = await FormatDocumentAsync(rewrittenRoot, spanToFormat, cancellationToken).ConfigureAwait(false);
168newDocument, spanToFormat, Options.FormattingOptions, cancellationToken).ConfigureAwait(false);
204leftTokenToTrailingTrivia, rightTokenToLeadingTrivia, cancellationToken).ConfigureAwait(false);
276var wrappingGroups = await ComputeWrappingGroupsAsync(cancellationToken).ConfigureAwait(false);
Wrapping\ChainedExpression\ChainedExpressionCodeActionComputer.cs (11)
88await GetSmartIndentationAfterAsync(firstPeriod, cancellationToken).ConfigureAwait(false))));
109await GetWrapEditsAsync(wrappingColumn: 0, align: false, cancellationToken).ConfigureAwait(false),
110FeaturesResources.Wrapping, FeaturesResources.Wrap_call_chain, cancellationToken).ConfigureAwait(false));
112await GetWrapEditsAsync(wrappingColumn: 0, align: true, cancellationToken).ConfigureAwait(false),
113FeaturesResources.Wrapping, FeaturesResources.Wrap_and_align_call_chain, cancellationToken).ConfigureAwait(false));
117=> actions.Add(await TryCreateCodeActionAsync(GetUnwrapEdits(), FeaturesResources.Wrapping, FeaturesResources.Unwrap_call_chain, cancellationToken).ConfigureAwait(false));
122await GetWrapEditsAsync(Options.WrappingColumn, align: false, cancellationToken).ConfigureAwait(false),
123FeaturesResources.Wrapping, FeaturesResources.Wrap_long_call_chain, cancellationToken).ConfigureAwait(false));
125await GetWrapEditsAsync(Options.WrappingColumn, align: true, cancellationToken).ConfigureAwait(false),
126FeaturesResources.Wrapping, FeaturesResources.Wrap_and_align_long_call_chain, cancellationToken).ConfigureAwait(false));
137var indentationTrivia = align ? _firstPeriodIndentationTrivia : await _smartIndentTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false);
Wrapping\SeparatedSyntaxList\SeparatedSyntaxListCodeActionComputer.cs (28)
91_singleIndentationTrivia = AsyncLazy.Create(async cancellationToken => generator.Whitespace(await GetSingleIndentationAsync(cancellationToken).ConfigureAwait(false)));
92_braceIndentationTrivia = AsyncLazy.Create(async cancellationToken => generator.Whitespace(await GetBraceTokenIndentationAsync(cancellationToken).ConfigureAwait(false)));
99? Edit.UpdateBetween(_listSyntax.GetFirstToken(), NewLineTrivia, await _singleIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false), _listItems[0])
126: await _singleIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false);
147result.Add(await GetWrapEveryGroupAsync(cancellationToken).ConfigureAwait(false));
148result.Add(await GetUnwrapGroupAsync(cancellationToken).ConfigureAwait(false));
149result.Add(await GetWrapLongGroupAsync(cancellationToken).ConfigureAwait(false));
163parentTitle, WrappingStyle.UnwrapFirst_IndentRest, cancellationToken).ConfigureAwait(false));
172parentTitle, WrappingStyle.WrapFirst_IndentRest, cancellationToken).ConfigureAwait(false));
181parentTitle, WrappingStyle.WrapFirst_IndentRest, wrappingColumn: int.MaxValue, cancellationToken).ConfigureAwait(false);
194var edits = await GetUnwrapAllEditsAsync(wrappingStyle, cancellationToken).ConfigureAwait(false);
199return await TryCreateCodeActionAsync(edits, parentTitle, title, cancellationToken).ConfigureAwait(false);
243parentTitle, WrappingStyle.UnwrapFirst_AlignRest, wrappingColumn, cancellationToken).ConfigureAwait(false));
250parentTitle, WrappingStyle.WrapFirst_IndentRest, wrappingColumn, cancellationToken).ConfigureAwait(false));
258parentTitle, WrappingStyle.UnwrapFirst_IndentRest, wrappingColumn, cancellationToken).ConfigureAwait(false));
279var indentationTrivia = await GetIndentationTriviaAsync(wrappingStyle, cancellationToken).ConfigureAwait(false);
282wrappingStyle, indentationTrivia, wrappingColumn, cancellationToken).ConfigureAwait(false);
285return await TryCreateCodeActionAsync(edits, parentTitle, title, cancellationToken).ConfigureAwait(false);
297await _braceIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false),
349await _braceIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false),
377parentTitle, WrappingStyle.UnwrapFirst_AlignRest, cancellationToken).ConfigureAwait(false));
386parentTitle, WrappingStyle.WrapFirst_IndentRest, cancellationToken).ConfigureAwait(false));
395parentTitle, WrappingStyle.UnwrapFirst_IndentRest, cancellationToken).ConfigureAwait(false));
406var indentationTrivia = await GetIndentationTriviaAsync(wrappingStyle, cancellationToken).ConfigureAwait(false);
408var edits = await GetWrapEachEditsAsync(wrappingStyle, indentationTrivia, cancellationToken).ConfigureAwait(false);
411return await TryCreateCodeActionAsync(edits, parentTitle, title, cancellationToken).ConfigureAwait(false);
432await _braceIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false),
459await _braceIndentationTrivia.GetValueAsync(cancellationToken).ConfigureAwait(false),
Microsoft.CodeAnalysis.InteractiveHost (34)
Microsoft.CodeAnalysis.LanguageServer (4)
Microsoft.CodeAnalysis.LanguageServer.Protocol (164)
Extensions\ProtocolConversions.cs (6)
147var insertionChar = await GetInsertionCharacterAsync(document, position, cancellationToken).ConfigureAwait(false);
377documentSpan.Document, documentSpan.SourceSpan, isStale: false, cancellationToken).ConfigureAwait(false);
419var mappedResults = await GetMappedSpanResultAsync(oldDocument, [.. textChanges.Select(tc => tc.Span)], cancellationToken).ConfigureAwait(false);
474var result = await GetMappedSpanResultAsync(document, [textSpan], cancellationToken).ConfigureAwait(false);
476return await ConvertTextSpanToLocationAsync(document, textSpan, isStale, cancellationToken).ConfigureAwait(false);
480return await ConvertTextSpanToLocationAsync(document, textSpan, isStale, cancellationToken).ConfigureAwait(false);
Features\CodeCleanup\AbstractCodeCleanupService.cs (10)
41thirdPartyDiagnosticIdsAndTitles = await GetThirdPartyDiagnosticIdsAndTitlesAsync(document, cancellationToken).ConfigureAwait(false);
65document, enabledDiagnostics.Diagnostics, progressTracker, cancellationToken).ConfigureAwait(false);
70document, thirdPartyDiagnosticIdsAndTitles, progressTracker, cancellationToken).ConfigureAwait(false);
78document, enabledDiagnostics.OrganizeUsings, cancellationToken).ConfigureAwait(false);
89document = await Formatter.FormatAsync(document, formattingOptions, cancellationToken).ConfigureAwait(false);
97document, thirdPartyDiagnosticIdsAndTitles, progressTracker, cancellationToken).ConfigureAwait(false);
140document, diagnosticSet.DiagnosticIds, diagnosticSet.IsAnyDiagnosticIdExplicitlyEnabled, progressTracker, cancellationToken).ConfigureAwait(false);
161document, diagnosticId, minimumSeverity, progressTracker, cancellationToken).ConfigureAwait(false);
184new FixAllContext(fixCollection.FixAllState!, progressTracker, cancellationToken)).ConfigureAwait(false);
229document, diagnosticId, DiagnosticSeverity.Warning, progressTracker, cancellationToken).ConfigureAwait(false);
Features\UnifiedSuggestions\UnifiedSuggestedActionsSource.cs (9)
56var organizedFixes = await OrganizeFixesAsync(workspace, originalSolution, text, filteredFixes, cancellationToken).ConfigureAwait(false);
138var unifiedSuggestedAction = await GetUnifiedSuggestedActionAsync(originalSolution, fix.Action, fix).ConfigureAwait(false);
152var unifiedNestedAction = await GetUnifiedSuggestedActionAsync(originalSolution, nestedAction, fix).ConfigureAwait(false);
171await getFixAllSuggestedActionSetAsync(action).ConfigureAwait(false));
454var orderedRefactoring = await OrganizeRefactoringsAsync(workspace, document, selection, refactoring, cancellationToken).ConfigureAwait(false);
517var unifiedActionSet = await GetUnifiedSuggestedActionSetAsync(action, applicableToSpan, selection, cancellationToken).ConfigureAwait(false);
546var unifiedAction = await GetUnifiedSuggestedActionSetAsync(nestedAction, applicableToSpan, selection, cancellationToken).ConfigureAwait(false);
566workspace, cancellationToken).ConfigureAwait(false);
614var documentsAndSpans = await fixAllState.GetFixAllSpansAsync(cancellationToken).ConfigureAwait(false);
Handler\Completion\CompletionHandler.cs (9)
54.ConfigureAwait(false);
66cancellationToken).ConfigureAwait(false);
84.ConfigureAwait(false);
97completionContext, document, documentText, position, completionOptions, capabilityHelper, completionService, completionListCache, completionListMaxSize, cancellationToken).ConfigureAwait(false);
106.ConfigureAwait(false);
123var completionTrigger = await ProtocolConversions.LSPToRoslynCompletionTriggerAsync(context, document, position, cancellationToken).ConfigureAwait(false);
132result = await CalculateListAsync(document, position, originalTrigger, completionOptions, completionService, completionListCache, cancellationToken).ConfigureAwait(false);
137result = await CalculateListAsync(document, position, completionTrigger, completionOptions, completionService, completionListCache, cancellationToken).ConfigureAwait(false);
174var completionList = await completionService.GetCompletionsAsync(document, position, completionOptions, document.Project.Solution.Options, completionTrigger, cancellationToken: cancellationToken).ConfigureAwait(false);
Handler\Completion\CompletionResultFactory.cs (15)
79lspCompletionItems.Add(await CreateLSPCompletionItemAsync(item, typedText).ConfigureAwait(false));
130cancellationToken).ConfigureAwait(false);
338cancellationToken).ConfigureAwait(false);
518var completionChange = await GetCompletionChangeOrDisplayNameInCaseOfExceptionAsync(completionService, document, item, cancellationToken).ConfigureAwait(false);
534var completionChange = await GetCompletionChangeOrDisplayNameInCaseOfExceptionAsync(completionService, document, selectedItem, cancellationToken).ConfigureAwait(false);
536var sourceText = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
557return await completionService.GetChangeAsync(document, completionItem, cancellationToken: cancellationToken).ConfigureAwait(false);
594document, roslynItem, completionOptions, symbolDescriptionOptions, cancellationToken).ConfigureAwait(false);
607roslynItem, document, completionService, cancellationToken).ConfigureAwait(false);
613document, completionService, roslynItem, capabilityHelper.SupportSnippets, insertNewPositionPlaceholder: false, cancellationToken).ConfigureAwait(false);
643document, roslynItem, completionOptions, symbolDescriptionOptions, cancellationToken).ConfigureAwait(false);
662var sourceText = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
664document, completionService, roslynItem, capabilityHelper.SupportSnippets, insertNewPositionPlaceholder: true, cancellationToken).ConfigureAwait(false);
682var completionChange = await GetCompletionChangeOrDisplayNameInCaseOfExceptionAsync(completionService, document, selectedItem, cancellationToken).ConfigureAwait(false);
687var documentText = await document.GetTextAsync(cancellationToken).ConfigureAwait(false);
Handler\Hover\HoverHandler.cs (4)
78.ConfigureAwait(false);
83document, position, options, supportsVSExtensions, supportsMarkdown, cancellationToken).ConfigureAwait(false);
102? await CreateVsHoverAsync(document, info, options, cancellationToken).ConfigureAwait(false)
103: await CreateDefaultHoverAsync(document, info, supportsMarkdown, cancellationToken).ConfigureAwait(false);
Handler\InlineCompletions\InlineCompletionsHandler.cs (5)
108var item = await GetInlineCompletionItemsAsync(context.Logger, document, linePosition, request.Options, _xmlSnippetParser, cancellationToken).ConfigureAwait(false);
153var formattingOptions = await ProtocolConversions.GetFormattingOptionsAsync(options, document, cancellationToken).ConfigureAwait(false);
156var formattedLspSnippet = await GetFormattedLspSnippetAsync(parsedSnippet, wordOnLeft.Value, document, sourceText, formattingOptions, simplifierOptions, cancellationToken).ConfigureAwait(false);
183originalDocument, originalSourceText, snippetShortcut, parsedSnippet, simplifierOptions, cancellationToken).ConfigureAwait(false);
286part = await functionPart.WithSnippetFunctionResultAsync(documentWithDefaultSnippet, new TextSpan(locationInDefaultSnippet, part.DefaultText.Length), simplifierOptions, cancellationToken).ConfigureAwait(false);
Handler\OnAutoInsert\OnAutoInsertHandler.cs (5)
76var formattingOptions = await ProtocolConversions.GetFormattingOptionsAsync(lspFormattingOptions, document, cancellationToken).ConfigureAwait(false);
84document, linePosition, character, service, docCommentOptions, cancellationToken).ConfigureAwait(false);
103document, servicesForDocument, linePosition, indentationOptions, cancellationToken).ConfigureAwait(false);
154var serviceAndContext = await GetBraceCompletionContextAsync(servicesForDocument, position, document, cancellationToken).ConfigureAwait(false);
195var textChange = await GetCollapsedChangeAsync(textChanges, document, cancellationToken).ConfigureAwait(false);
Handler\References\FindUsagesLSPContext.cs (6)
119definition.Tags.GetFirstGlyph(), symbolUsageInfo: null, isWrittenTo: false, cancellationToken).ConfigureAwait(false);
170definitionGlyph: Glyph.None, reference.SymbolUsageInfo, reference.IsWrittenTo, cancellationToken).ConfigureAwait(false);
191var text = await ComputeTextAsync(definitionId, documentSpan, definitionText, isWrittenTo, cancellationToken).ConfigureAwait(false);
195var location = await ComputeLocationAsync(documentSpan, cancellationToken).ConfigureAwait(false);
251return await ProtocolConversions.DocumentSpanToLocationAsync(documentSpan.Value, cancellationToken).ConfigureAwait(false);
255var symbol = await SymbolFinder.FindSymbolAtPositionAsync(_document, _position, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests (153)
Completion\CompletionResolveTests.cs (16)
63label: "A").ConfigureAwait(false);
69testLspServer, clientCompletionItem).ConfigureAwait(false);
85var clientCompletionItem = await GetCompletionItemToResolveAsync<LSP.VSInternalCompletionItem>(testLspServer, label: "A").ConfigureAwait(false);
91testLspServer, clientCompletionItem).ConfigureAwait(false);
109var clientCompletionItem = await GetCompletionItemToResolveAsync<LSP.VSInternalCompletionItem>(testLspServer, label: "M()").ConfigureAwait(false);
111testLspServer, clientCompletionItem).ConfigureAwait(false);
153label: "M()").ConfigureAwait(false);
156testLspServer, clientCompletionItem).ConfigureAwait(false);
245label: "AMethod").ConfigureAwait(false);
263clientCompletionItem).ConfigureAwait(false);
306label: "AMethod").ConfigureAwait(false);
321clientCompletionItem).ConfigureAwait(false);
338var clientCompletionItem = await GetCompletionItemToResolveAsync<LSP.VSInternalCompletionItem>(testLspServer, label: "(byte)").ConfigureAwait(false);
341testLspServer, clientCompletionItem).ConfigureAwait(false);
361var clientCompletionItem = await GetCompletionItemToResolveAsync<LSP.VSInternalCompletionItem>(testLspServer, label: "svm").ConfigureAwait(false);
366testLspServer, clientCompletionItem).ConfigureAwait(false);
Completion\CompletionTests.cs (44)
100var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
151var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
180var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
214var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
253var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
281var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
359var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
388var results = (LSP.VSInternalCompletionList)await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
418var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
443var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
479var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
516var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
553var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
607var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
639await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
645await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
653await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
663await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
698var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
726var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
754var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
780var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
830var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
884var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
938var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
951results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1004var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1017results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1070var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1082results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1094results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1107results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1165var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1176results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1228var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1288var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1305results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1320results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1352var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1404var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1417results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1443var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1498var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
1526var results = await RunGetCompletionsAsync(testLspServer, completionParams).ConfigureAwait(false);
Diagnostics\PullDiagnosticTests.cs (13)
244var results = await RunGetDocumentPullDiagnosticsAsync(testLspServer, document.GetURI(), useVSDiagnostics).ConfigureAwait(false);
252results = await RunGetDocumentPullDiagnosticsAsync(testLspServer, document.GetURI(), useVSDiagnostics, results.Single().ResultId).ConfigureAwait(false);
524await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
576await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1419await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1625await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1707await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1732results = await RunGetWorkspacePullDiagnosticsAsync(testLspServer, useVSDiagnostics, previousResults: previousResultIds).ConfigureAwait(false);
1781await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1849await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1912await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
1968await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
2012await using var testLspServer = await CreateTestWorkspaceFromXmlAsync(workspaceXml, mutatingLspWorkspace, BackgroundAnalysisScope.FullSolution, useVSDiagnostics).ConfigureAwait(false);
Workspaces\LspWorkspaceManagerTests.cs (37)
38var (_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
44(_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
51var (_, closedDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
90var (_, firstDocumentWithChange) = await GetLspWorkspaceAndDocumentAsync(firstDocumentUri, testLspServer).ConfigureAwait(false);
91var (_, secondDocumentUnchanged) = await GetLspWorkspaceAndDocumentAsync(secondDocumentUri, testLspServer).ConfigureAwait(false);
125var (_, openedDocument) = await GetLspWorkspaceAndDocumentAsync(firstDocumentUri, testLspServer).ConfigureAwait(false);
130(_, secondDocument) = await GetLspWorkspaceAndDocumentAsync(secondDocumentUri, testLspServer).ConfigureAwait(false);
163(_, openedDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
196(_, openedDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
230var (_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(newDocumentUri, testLspServer).ConfigureAwait(false);
255var (miscWorkspace, miscDocument) = await GetLspWorkspaceAndDocumentAsync(newDocumentUri, testLspServer).ConfigureAwait(false);
262(_, miscDocument) = await GetLspWorkspaceAndDocumentAsync(newDocumentUri, testLspServer).ConfigureAwait(false);
271var (documentWorkspace, document) = await GetLspWorkspaceAndDocumentAsync(newDocumentUri, testLspServer).ConfigureAwait(false);
318var (_, hostSolution) = await GetLspHostWorkspaceAndSolutionAsync(testLspServer).ConfigureAwait(false);
342var (_, solution) = await GetLspHostWorkspaceAndSolutionAsync(testLspServer).ConfigureAwait(false);
380var (firstWorkspace, firstDocument) = await GetLspWorkspaceAndDocumentAsync(firstWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
385var (secondWorkspace, secondDocument) = await GetLspWorkspaceAndDocumentAsync(secondWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
394var (_, changedFirstDocument) = await GetLspWorkspaceAndDocumentAsync(firstWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
401var (_, unchangedSecondDocument) = await GetLspWorkspaceAndDocumentAsync(secondWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
435var (firstWorkspace, firstDocument) = await GetLspWorkspaceAndDocumentAsync(firstWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
440var (secondWorkspace, secondDocument) = await GetLspWorkspaceAndDocumentAsync(secondWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
450var (_, secondDocumentChangedProject) = await GetLspWorkspaceAndDocumentAsync(secondWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
456var (_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(firstWorkspaceDocumentUri, testLspServer).ConfigureAwait(false);
486var (_, documentServerTwo) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServerTwo).ConfigureAwait(false);
506(_, documentServerOne) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServerOne).ConfigureAwait(false);
509(_, documentServerTwo) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServerTwo).ConfigureAwait(false);
527var (_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
550var (workspace1, document1) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
569(workspace1, document1) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
587(workspace1, document1) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
607var (workspace, document) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
623(workspace, document) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
646var (workspace, originalDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
659var (_, newDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
748var (_, removedSourceGeneratorDocument) = await GetLspWorkspaceAndDocumentAsync(sourceGeneratorDocumentUri, testLspServer).ConfigureAwait(false);
759var (_, lspDocument) = await GetLspWorkspaceAndDocumentAsync(documentUri, testLspServer).ConfigureAwait(false);
772var (workspace, _, document) = await testLspServer.GetManager().GetLspDocumentInfoAsync(CreateTextDocumentIdentifier(uri), CancellationToken.None).ConfigureAwait(false);
Microsoft.CodeAnalysis.PerformanceSensitiveAnalyzers (71)
Microsoft.CodeAnalysis.PublicApiAnalyzers (25)
Microsoft.CodeAnalysis.PublicApiAnalyzers.CodeFixes (17)
Microsoft.CodeAnalysis.Remote.ServiceHub (46)
Host\RemoteWorkspace.SolutionCreator.cs (9)
65solution, oldSolutionChecksums, newSolutionChecksums, cancellationToken).ConfigureAwait(false);
227solution, isConeSync, oldProjectIdToStateChecksums, newProjectIdToStateChecksums, cancellationToken).ConfigureAwait(false);
333solution.GetRequiredProject(projectId), oldProjectChecksums, newProjectChecksums, cancellationToken).ConfigureAwait(false);
395cancellationToken).ConfigureAwait(false);
407cancellationToken).ConfigureAwait(false);
419cancellationToken).ConfigureAwait(false);
469return await UpdateDocumentsAsync(project, addDocuments, removeDocuments, oldDocumentIdToChecksums, newDocumentIdToChecksums, cancellationToken).ConfigureAwait(false);
530project = await UpdateDocumentAsync(document, oldDocumentChecksums, newDocumentChecksums, cancellationToken).ConfigureAwait(false);
545document = await UpdateDocumentInfoAsync(document, newDocumentChecksums.attributeChecksum, cancellationToken).ConfigureAwait(false);
Services\SymbolFinder\RemoteSymbolFinderService.cs (5)
106project, query, criteria, cancellationToken).ConfigureAwait(false);
122solution, name, ignoreCase, criteria, cancellationToken).ConfigureAwait(false);
141project, name, ignoreCase, criteria, cancellationToken).ConfigureAwait(false);
153solution, pattern, criteria, cancellationToken).ConfigureAwait(false);
167project, pattern, criteria, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.Remote.Workspaces (11)
AbstractAssetProvider.cs (8)
56AssetPathKind.SolutionAnalyzerReferences, solutionChecksums.AnalyzerReferences, cancellationToken).ConfigureAwait(false);
104await analyzerReferencesTask.ConfigureAwait(false),
112await documentInfosTask.ConfigureAwait(false),
113await projectReferencesTask.ConfigureAwait(false),
114await metadataReferencesTask.ConfigureAwait(false),
116await additionalDocumentInfosTask.ConfigureAwait(false),
117await analyzerConfigDocumentInfosTask.ConfigureAwait(false),
127documentInfos.Add(await CreateDocumentInfoAsync(documentId, attributeChecksum, textChecksum, cancellationToken).ConfigureAwait(false));
Microsoft.CodeAnalysis.ResxSourceGenerator (25)
Microsoft.CodeAnalysis.Scripting (4)
Microsoft.CodeAnalysis.Scripting.TestUtilities (10)
ScriptTaskExtensions.cs (10)
17return await (await task.ConfigureAwait(false)).ContinueWithAsync(code, options, cancellationToken).ConfigureAwait(false);
22return await (await task.ConfigureAwait(false)).ContinueWithAsync(code, options, cancellationToken).ConfigureAwait(false);
27return await (await task.ConfigureAwait(false)).ContinueWithAsync<T>(code, options, cancellationToken).ConfigureAwait(false);
32return await (await task.ConfigureAwait(false)).ContinueWithAsync<T>(code, options, cancellationToken).ConfigureAwait(false);
37return await (await task.ConfigureAwait(false)).ContinueWithAsync(code, options, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.TestAnalyzerReference (1)
Microsoft.CodeAnalysis.Threading.Package (5)
Microsoft.CodeAnalysis.VisualBasic.CodeStyle.Fixes (8)
Microsoft.CodeAnalysis.VisualBasic.EditorFeatures (19)
Microsoft.CodeAnalysis.VisualBasic.Features (96)
CodeFixes\GenerateEvent\GenerateEventCodeFixProvider.vb (9)
45Dim root = Await context.Document.GetSyntaxRootAsync(context.CancellationToken).ConfigureAwait(False)
77Dim semanticModel = Await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(False)
108Dim sourceDefinition = Await SymbolFinder.FindSourceDefinitionAsync(targetType, document.Project.Solution, cancellationToken).ConfigureAwait(False)
132document.Project.Solution, eventHandlerName, Not syntaxFactService.IsCaseSensitive, SymbolFilter.Type, cancellationToken).ConfigureAwait(False)
252Dim semanticModel = Await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(False)
259Dim targetType = TryCast(Await SymbolFinder.FindSourceDefinitionAsync(semanticModel.GetSymbolInfo(node.Left, cancellationToken).Symbol, document.Project.Solution, cancellationToken).ConfigureAwait(False), INamedTypeSymbol)
319Dim semanticModel = Await document.GetSemanticModelAsync(cancellationToken).ConfigureAwait(False)
350targetType = TryCast(Await SymbolFinder.FindSourceDefinitionAsync(withEventsProperty.Type, document.Project.Solution, cancellationToken).ConfigureAwait(False), INamedTypeSymbol)
354targetType = TryCast(Await SymbolFinder.FindSourceDefinitionAsync(targetType, document.Project.Solution, cancellationToken).ConfigureAwait(False), INamedTypeSymbol)
Microsoft.CodeAnalysis.VisualBasic.Workspaces (8)
Microsoft.CodeAnalysis.Workspaces (555)
Classification\AbstractClassificationService.cs (7)
75var client = await RemoteHostClient.TryGetClientAsync(project, cancellationToken).ConfigureAwait(false);
83var isFullyLoaded = await workspaceStatusService.IsFullyLoadedAsync(cancellationToken).ConfigureAwait(false);
84if (await TryGetCachedClassificationsAsync(document, textSpans, type, client, isFullyLoaded, result, cancellationToken).ConfigureAwait(false))
120document, cancellationToken).ConfigureAwait(false);
156var reassignedVariableSpans = await reassignedVariableService.GetLocationsAsync(document, textSpans, cancellationToken).ConfigureAwait(false);
164var obsoleteSymbolSpans = await obsoleteSymbolService.GetLocationsAsync(document, textSpans, cancellationToken).ConfigureAwait(false);
203var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
CodeActions\CodeAction.cs (17)
247var operations = await this.ComputeOperationsAsync(progress, cancellationToken).ConfigureAwait(false);
251return await PostProcessAsync(originalSolution, operations, cancellationToken).ConfigureAwait(false);
268var operations = await this.ComputePreviewOperationsAsync(cancellationToken).ConfigureAwait(false);
272return await PostProcessAsync(originalSolution, operations, cancellationToken).ConfigureAwait(false);
284var changedSolution = await GetChangedSolutionAsync(CodeAnalysisProgress.None, cancellationToken).ConfigureAwait(false);
305var operations = await ComputeOperationsAsync(cancellationToken).ConfigureAwait(false);
310var changedSolution = await GetChangedSolutionAsync(progress, cancellationToken).ConfigureAwait(false);
324=> await ComputeOperationsAsync(CodeAnalysisProgress.None, cancellationToken).ConfigureAwait(false);
334var changedDocument = await GetChangedDocumentAsync(cancellationToken).ConfigureAwait(false);
350return await GetChangedSolutionAsync(cancellationToken).ConfigureAwait(false);
356var changedDocument = await GetChangedDocumentAsync(progress, cancellationToken).ConfigureAwait(false);
363var solution = await this.GetChangedSolutionAsync(progressTracker, cancellationToken).ConfigureAwait(false);
405var solution = await GetChangedSolutionAsync(progress, cancellationToken).ConfigureAwait(false);
409return await PostProcessChangesAsync(originalSolution, solution, progress, this.Cleanup, cancellationToken).ConfigureAwait(false);
436originalSolution, ac.ChangedSolution, CodeAnalysisProgress.None, this.Cleanup, cancellationToken).ConfigureAwait(false)));
687return await base.ComputePreviewOperationsAsync(cancellationToken).ConfigureAwait(false);
689var newDocument = await _createChangedDocumentPreview(CodeAnalysisProgress.None, cancellationToken).ConfigureAwait(false);
CodeActions\CodeAction_Cleanup.cs (10)
77var document1 = await Formatter.FormatAsync(document, Formatter.Annotation, options.FormattingOptions, cancellationToken).ConfigureAwait(false);
80var document2 = await Formatter.FormatAsync(document1, SyntaxAnnotation.ElasticAnnotation, options.FormattingOptions, cancellationToken).ConfigureAwait(false);
117cancellationToken).ConfigureAwait(false);
128var documentIdsAndOptionsToClean = await GetDocumentIdsAndOptionsToCleanAsync().ConfigureAwait(false);
132changedSolution, documentIdsAndOptionsToClean, progress, passes, cancellationToken).ConfigureAwait(false);
168cancellationToken).ConfigureAwait(false);
185currentSolution = await RunParallelCleanupPassAsync(currentSolution, cleanupPass).ConfigureAwait(false);
195using var _ = await RemoteKeepAliveSession.CreateAsync(solution, cancellationToken).ConfigureAwait(false);
213var cleanedDocument = await cleanupDocumentAsync(document, options, cancellationToken).ConfigureAwait(false);
222cancellationToken).ConfigureAwait(false);
CodeCleanup\AbstractCodeCleanerService.cs (9)
48return await IterateAllCodeCleanupProvidersAsync(document, document, options, r => [r.FullSpan], codeCleaners, cancellationToken).ConfigureAwait(false);
58return await IterateAllCodeCleanupProvidersAsync(document, document, options, n => [n.FullSpan], codeCleaners, cancellationToken).ConfigureAwait(false);
69codeCleaners, cancellationToken).ConfigureAwait(false);
90return await IterateAllCodeCleanupProvidersAsync(root, root, options, r => [r.FullSpan], services, codeCleaners, cancellationToken).ConfigureAwait(false);
100return await IterateAllCodeCleanupProvidersAsync(root, root, options, n => [n.FullSpan], services, codeCleaners, cancellationToken).ConfigureAwait(false);
110services, codeCleaners, cancellationToken).ConfigureAwait(false);
469var originalDocHasErrors = await annotatedDocument.HasAnyErrorsAsync(cancellationToken).ConfigureAwait(false);
496currentDocument = await codeCleaner.CleanupAsync(currentDocument, spans, options, cancellationToken).ConfigureAwait(false);
573currentRoot = await codeCleaner.CleanupAsync(currentRoot, spans, options, services, cancellationToken).ConfigureAwait(false);
CodeCleanup\CodeCleaner.cs (3)
53return await CleanupAsync(document, new TextSpan(0, text.Length), options, providers, cancellationToken: cancellationToken).ConfigureAwait(false);
63return await CleanupAsync(document, [.. root.GetAnnotatedNodesAndTokens(annotation).Select(n => n.Span)], options, providers, cancellationToken: cancellationToken).ConfigureAwait(false);
80return await cleanupService.CleanupAsync(document, spans, options, providers, cancellationToken).ConfigureAwait(false);
Diagnostics\CompilationWithAnalyzersPair.cs (8)
69? await ProjectCompilationWithAnalyzers.GetAnalysisResultAsync(cancellationToken).ConfigureAwait(false)
72? await HostCompilationWithAnalyzers.GetAnalysisResultAsync(cancellationToken).ConfigureAwait(false)
81? await ProjectCompilationWithAnalyzers!.GetAnalysisResultAsync(tree, filterSpan, projectAnalyzers, cancellationToken).ConfigureAwait(false)
84? await HostCompilationWithAnalyzers!.GetAnalysisResultAsync(tree, filterSpan, hostAnalyzers, cancellationToken).ConfigureAwait(false)
93? await ProjectCompilationWithAnalyzers!.GetAnalysisResultAsync(file, filterSpan, projectAnalyzers, cancellationToken).ConfigureAwait(false)
96? await HostCompilationWithAnalyzers!.GetAnalysisResultAsync(file, filterSpan, hostAnalyzers, cancellationToken).ConfigureAwait(false)
105? await ProjectCompilationWithAnalyzers!.GetAnalysisResultAsync(model, filterSpan, projectAnalyzers, cancellationToken).ConfigureAwait(false)
108? await HostCompilationWithAnalyzers!.GetAnalysisResultAsync(model, filterSpan, hostAnalyzers, cancellationToken).ConfigureAwait(false)
Diagnostics\Extensions.cs (13)
34result.Add(await diagnostic.ToDiagnosticAsync(project, cancellationToken).ConfigureAwait(false));
122treeToAnalyze = await document.GetSyntaxTreeAsync(cancellationToken).ConfigureAwait(false);
327var result = await GetAnalysisResultAsync(compilationWithAnalyzers, documentAnalysisScope, cancellationToken).ConfigureAwait(false);
329documentAnalysisScope, project, analyzerInfoCache, cancellationToken).ConfigureAwait(false);
340return await compilationWithAnalyzers.GetAnalysisResultAsync(cancellationToken).ConfigureAwait(false);
352return await compilationWithAnalyzers.GetAnalysisResultAsync(tree, documentAnalysisScope.Span, documentAnalysisScope.ProjectAnalyzers, documentAnalysisScope.HostAnalyzers, cancellationToken).ConfigureAwait(false);
356return await compilationWithAnalyzers.GetAnalysisResultAsync(documentAnalysisScope.AdditionalFile, documentAnalysisScope.Span, documentAnalysisScope.ProjectAnalyzers, documentAnalysisScope.HostAnalyzers, cancellationToken).ConfigureAwait(false);
361return await compilationWithAnalyzers.GetAnalysisResultAsync(model, documentAnalysisScope.Span, documentAnalysisScope.ProjectAnalyzers, documentAnalysisScope.HostAnalyzers, cancellationToken).ConfigureAwait(false);
407cancellationToken).ConfigureAwait(false);
492var projectChecksum = await project.State.GetChecksumAsync(cancellationToken).ConfigureAwait(false);
503solution.GetProject(projectRef.ProjectId), cancellationToken).ConfigureAwait(false));
513var remoteHostClient = await RemoteHostClient.TryGetClientAsync(project, cancellationToken).ConfigureAwait(false);
524return await result.Value.ToDiagnosticsAsync(project, cancellationToken).ConfigureAwait(false);
Editing\ImportAdder.cs (7)
34=> await AddImportsFromSyntaxesAsync(document, await GetSpansAsync(document, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
46=> await AddImportsFromSyntaxesAsync(document, await GetSpansAsync(document, annotation, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
64return await service.AddImportsAsync(document, spans, ImportAdderService.Strategy.AddImportsFromSyntaxes, addImportOptions, cancellationToken).ConfigureAwait(false);
71=> await AddImportsFromSyntaxesAsync(document, await GetSpansAsync(document, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
77=> await AddImportsFromSyntaxesAsync(document, await GetSpansAsync(document, annotation, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
89=> await AddImportsFromSymbolAnnotationAsync(document, await GetSpansAsync(document, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
95=> await AddImportsFromSymbolAnnotationAsync(document, await GetSpansAsync(document, annotation, cancellationToken).ConfigureAwait(false), options, cancellationToken).ConfigureAwait(false);
Editing\SymbolEditor.cs (19)
106return await GetSymbolAsync(ChangedSolution, project.Id, symbolId, cancellationToken).ConfigureAwait(false);
113return await GetSymbolAsync(ChangedSolution, project.Id, symbolId, cancellationToken).ConfigureAwait(false);
119var currentSymbol = await GetSymbolAsync(ChangedSolution, projectId, symbolId, cancellationToken).ConfigureAwait(false);
153var comp = await solution.GetProject(projectId).GetCompilationAsync(cancellationToken).ConfigureAwait(false);
185var currentSymbol = await this.GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
237var currentSymbol = await this.GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
242return await this.EditDeclarationAsync(currentSymbol, declaration, editAction, cancellationToken).ConfigureAwait(false);
286var editor = await DocumentEditor.CreateAsync(doc, cancellationToken).ConfigureAwait(false);
295var model = await newDoc.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
307return await this.GetCurrentSymbolAsync(currentSymbol, cancellationToken).ConfigureAwait(false);
369var currentSymbol = await this.GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
383return await this.EditDeclarationAsync(currentSymbol, decl, editAction, cancellationToken).ConfigureAwait(false);
401var currentSymbol = await this.GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
404var currentMember = await this.GetCurrentSymbolAsync(member, cancellationToken).ConfigureAwait(false);
416return await this.EditDeclarationAsync(currentSymbol, declaration, editAction, cancellationToken).ConfigureAwait(false);
458var currentSymbol = await this.GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
468var editor = await solutionEditor.GetDocumentEditorAsync(docId, cancellationToken).ConfigureAwait(false);
483var model = await doc.GetSemanticModelAsync(cancellationToken).ConfigureAwait(false);
500return await GetCurrentSymbolAsync(symbol, cancellationToken).ConfigureAwait(false);
FindSymbols\Declarations\DeclarationFinder_SourceDeclarations.cs (13)
43var client = await RemoteHostClient.TryGetClientAsync(solution.Services, cancellationToken).ConfigureAwait(false);
56return await RehydrateAsync(solution, result.Value, cancellationToken).ConfigureAwait(false);
60solution, name, ignoreCase, criteria, cancellationToken).ConfigureAwait(false);
81var client = await RemoteHostClient.TryGetClientAsync(project, cancellationToken).ConfigureAwait(false);
94return await RehydrateAsync(project.Solution, result.Value, cancellationToken).ConfigureAwait(false);
98project, name, ignoreCase, criteria, cancellationToken).ConfigureAwait(false);
114var client = await RemoteHostClient.TryGetClientAsync(solution.Services, cancellationToken).ConfigureAwait(false);
127return await RehydrateAsync(solution, result.Value, cancellationToken).ConfigureAwait(false);
131solution, pattern, criteria, cancellationToken).ConfigureAwait(false);
147var client = await RemoteHostClient.TryGetClientAsync(project, cancellationToken).ConfigureAwait(false);
160return await RehydrateAsync(project.Solution, result.Value, cancellationToken).ConfigureAwait(false);
164project, pattern, criteria, cancellationToken).ConfigureAwait(false);
219var symbolAndProjectIds = await searchAsync(query).ConfigureAwait(false);
FindSymbols\FindReferences\DependentProjectsFinder.cs (6)
49var dependentProjects = await GetDependentProjectsWorkerAsync(solution, symbols, cancellationToken).ConfigureAwait(false);
86solution, (assembly, sourceProject), maxVisibility, cancellationToken).ConfigureAwait(false);
154solution, symbolOrigination, visibility, cancellationToken).ConfigureAwait(false);
210var compilation = await project.GetRequiredCompilationAsync(cancellationToken).ConfigureAwait(false);
271!await HasReferenceToAsync(symbolOrigination, project, cancellationToken).ConfigureAwait(false))
321project, symbolOrigination.assembly.Name, cancellationToken).ConfigureAwait(false);
FindSymbols\FindReferences\FindReferencesSearchEngine.cs (7)
95var disposable = await _progressTracker.AddSingleItemAsync(cancellationToken).ConfigureAwait(false);
101this, unifiedSymbols, includeImplementationsThroughDerivedTypes: true, cancellationToken).ConfigureAwait(false);
107await ReportGroupsSeriallyAsync(allSymbols, symbolToGroup, cancellationToken).ConfigureAwait(false);
111var projectsToSearch = await GetProjectsToSearchAsync(allSymbols, cancellationToken).ConfigureAwait(false);
152symbolSet.GetAllSymbols(), symbolToGroup, cancellationToken).ConfigureAwait(false);
186var linkedSymbols = await SymbolFinder.FindLinkedSymbolsAsync(symbol, _solution, cancellationToken).ConfigureAwait(false);
352symbol, project, cancellationToken).ConfigureAwait(false);
FindSymbols\FindReferences\FindReferencesSearchEngine.SymbolSet.cs (9)
81var initialSymbols = await DetermineInitialSearchSymbolsAsync(engine, searchSymbols, cancellationToken).ConfigureAwait(false);
85engine, initialSymbols, includeImplementationsThroughDerivedTypes, cancellationToken).ConfigureAwait(false);
135var sourceSymbol = await SymbolFinder.FindSourceDefinitionAsync(searchSymbol, solution, cancellationToken).ConfigureAwait(false);
195var mapped = await TryMapAndAddLinkedSymbolsAsync(symbol).ConfigureAwait(false);
205await TryMapAndAddLinkedSymbolsAsync(cascade).ConfigureAwait(false);
217foreach (var linked in await SymbolFinder.FindLinkedSymbolsAsync(symbol, solution, cancellationToken).ConfigureAwait(false))
251symbol, solution, projects, cancellationToken).ConfigureAwait(false);
258symbol, solution, projects, cancellationToken).ConfigureAwait(false);
288symbol, solution, projects, includeImplementationsThroughDerivedTypes, cancellationToken).ConfigureAwait(false);
FindSymbols\FindReferences\FindReferencesSearchEngine_FindReferencesInDocuments.cs (6)
51var symbolSet = await SymbolSet.DetermineInitialSearchSymbolsAsync(this, unifiedSymbols, cancellationToken).ConfigureAwait(false);
55[.. symbolSet], symbolToGroup, cancellationToken).ConfigureAwait(false);
157var converted = await ConvertLocationsAsync(@this, values, symbol, group, cancellationToken).ConfigureAwait(false);
225relationship = await ComputeInheritanceRelationshipAsync(key.searchSymbol, key.candidate).ConfigureAwait(false);
244this, [searchSymbol], includeImplementationsThroughDerivedTypes: false, cancellationToken).ConfigureAwait(false);
254this, [candidate], includeImplementationsThroughDerivedTypes: false, cancellationToken).ConfigureAwait(false);
FindSymbols\Shared\AbstractSyntaxIndex.cs (5)
57index = await GetIndexWorkerAsync(solutionKey, project, document, loadOnly, read, create, cancellationToken).ConfigureAwait(false);
101index = await LoadAsync(solutionKey, project, document, textChecksum, textAndDirectivesChecksum, read, cancellationToken).ConfigureAwait(false);
106index = await CreateIndexAsync(project, document, textChecksum, textAndDirectivesChecksum, create, cancellationToken).ConfigureAwait(false);
109await index.SaveAsync(solutionKey, project, document, cancellationToken).ConfigureAwait(false);
125var root = await syntaxTree.GetRootAsync(cancellationToken).ConfigureAwait(false);
FindSymbols\Shared\AbstractSyntaxIndex_Persistence.cs (5)
58return await LoadAsync(storageService, documentKey, textChecksum, stringTable, read, cancellationToken).ConfigureAwait(false) ??
59await LoadAsync(storageService, documentKey, textAndDirectivesChecksum, stringTable, read, cancellationToken).ConfigureAwait(false);
75using var stream = await storage.ReadStreamAsync(documentKey, s_persistenceName, checksum, cancellationToken).ConfigureAwait(false);
120var documentChecksumState = await document.GetStateChecksumsAsync(cancellationToken).ConfigureAwait(false);
176return await storage.WriteStreamAsync(documentKey, s_persistenceName, stream, this.Checksum, cancellationToken).ConfigureAwait(false);
FindSymbols\SymbolFinder_Declarations_CustomQueries.cs (5)
38solution, query, filter, cancellationToken).ConfigureAwait(false);
62var symbols = await FindSourceDeclarationsWithCustomQueryAsync(project, query, filter, cancellationToken).ConfigureAwait(false);
83project, query, filter, cancellationToken).ConfigureAwait(false);
103if (await project.ContainsSymbolsWithNameAsync(query.GetPredicate(), filter, cancellationToken).ConfigureAwait(false))
105var compilation = await project.GetRequiredCompilationAsync(cancellationToken).ConfigureAwait(false);
FindSymbols\SymbolFinder_Declarations_SourceDeclarations.cs (4)
32solution, name, ignoreCase, filter, cancellationToken).ConfigureAwait(false);
52project, name, ignoreCase, filter, cancellationToken).ConfigureAwait(false);
83solution, pattern, filter, cancellationToken).ConfigureAwait(false);
111project, pattern, filter, cancellationToken).ConfigureAwait(false);
FindSymbols\SymbolFinder_Hierarchy.cs (17)
29return await FindOverridesArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
50containingType, solution, projects, cancellationToken).ConfigureAwait(false);
66var sourceMember = await FindSourceDefinitionAsync(m, solution, cancellationToken).ConfigureAwait(false);
98cancellationToken).ConfigureAwait(false);
145? await FindDerivedClassesAsync(containingType, solution, projects, cancellationToken).ConfigureAwait(false)
169var sourceMethod = await FindSourceDefinitionAsync(interfaceMember, solution, cancellationToken).ConfigureAwait(false);
240return await FindDerivedClassesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
249type, solution, projects, transitive, DependentTypesKind.DerivedClasses, cancellationToken).ConfigureAwait(false);
276return await FindDerivedInterfacesArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
285type, solution, projects, transitive, DependentTypesKind.DerivedInterfaces, cancellationToken).ConfigureAwait(false);
312return await FindImplementationsArrayAsync(type, solution, transitive, projects, cancellationToken).ConfigureAwait(false);
321type, solution, projects, transitive, DependentTypesKind.ImplementingTypes, cancellationToken).ConfigureAwait(false);
345namedTypeSymbol, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
348return await FindMemberImplementationsArrayAsync(symbol, solution, projects, cancellationToken).ConfigureAwait(false);
366var classAndStructImplementations = await FindImplementationsAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
367var transitiveDerivedInterfaces = await FindDerivedInterfacesAsync(containingType, solution, transitive: true, projects, cancellationToken).ConfigureAwait(false);
376var sourceDef = await FindSourceDefinitionAsync(implementation, solution, cancellationToken).ConfigureAwait(false);
FindSymbols\SymbolTree\SymbolTreeInfo_Serialization.cs (3)
41var read = await LoadAsync(services, solutionKey, checksum, checksumMustMatch: true, keySuffix, cancellationToken).ConfigureAwait(false);
74await storage.WriteStreamAsync(key, stream, checksum, cancellationToken).ConfigureAwait(false);
97using var stream = await storage.ReadStreamAsync(key, checksumMustMatch ? checksum : null, cancellationToken).ConfigureAwait(false);
Rename\ConflictEngine\ConflictResolver.cs (8)
63var client = await RemoteHostClient.TryGetClientAsync(solution.Services, cancellationToken).ConfigureAwait(false);
75return await result.Value.RehydrateAsync(solution, cancellationToken).ConfigureAwait(false);
81var heavyweightLocations = await lightweightRenameLocations.ToSymbolicLocationsAsync(symbol, cancellationToken).ConfigureAwait(false);
86heavyweightLocations, replacementText, nonConflictSymbolKeys, cancellationToken).ConfigureAwait(false);
108renameLocations, renameSymbolDeclarationLocation, replacementText, nonConflictSymbolKeys, cancellationToken).ConfigureAwait(false);
210cancellationToken).ConfigureAwait(false);
303cancellationToken).ConfigureAwait(false);
410var originalsourcesymbol = await SymbolFinder.FindSourceDefinitionAsync(symbol, solution, cancellationToken).ConfigureAwait(false);
Rename\ConflictEngine\ConflictResolver.Session.cs (14)
96var (documentsIdsToBeCheckedForConflict, possibleNameConflicts) = await FindDocumentsAndPossibleNameConflictsAsync().ConfigureAwait(false);
142possibleNameConflicts).ConfigureAwait(false));
150conflictLocations).ConfigureAwait(false);
202conflictResolution.UpdateCurrentSolution(await renamedSpansTracker.SimplifyAsync(conflictResolution.CurrentSolution, documentsByProject, _replacementTextValid, _renameAnnotations, _cancellationToken).ConfigureAwait(false));
204intermediateSolution, documentsByProject, _renameAnnotations, _cancellationToken).ConfigureAwait(false);
210var renamedSymbolInNewSolution = await GetRenamedSymbolInCurrentSolutionAsync(conflictResolution).ConfigureAwait(false);
270documentIdErrorStateLookup.Add(documentId, await originalDoc.HasAnyErrorsAsync(_cancellationToken).ConfigureAwait(false));
313var renamedSymbolInNewSolution = await GetRenamedSymbolInCurrentSolutionAsync(conflictResolution).ConfigureAwait(false);
344var nonConflictSymbols = await GetNonConflictSymbolsAsync(currentProject).ConfigureAwait(false);
387await CheckForConflictAsync(conflictResolution, renamedSymbolInNewSolution, conflictAnnotation, newReferencedSymbols).ConfigureAwait(false);
473var compilation = await currentProject.GetRequiredCompilationAsync(_cancellationToken).ConfigureAwait(false);
603var overridingSymbol = await SymbolFinder.FindSymbolAtPositionAsync(solution.GetRequiredDocument(newLocation.SourceTree), newLocation.SourceSpan.Start, cancellationToken: _cancellationToken).ConfigureAwait(false);
685var newSymbol = await SymbolFinder.FindSymbolAtPositionAsync(document, start, cancellationToken: _cancellationToken).ConfigureAwait(false);
792var originalSyntaxRoot = await semanticModel.SyntaxTree.GetRootAsync(_cancellationToken).ConfigureAwait(false);
Rename\Renamer.cs (7)
53var resolution = await RenameSymbolAsync(solution, symbol, newName, options, nonConflictSymbolKeys: default, cancellationToken).ConfigureAwait(false);
117var renameAction = await RenameSymbolDocumentAction.TryCreateAsync(document, newDocumentName, cancellationToken).ConfigureAwait(false);
160var client = await RemoteHostClient.TryGetClientAsync(solution.Services, cancellationToken).ConfigureAwait(false);
175return await result.Value.RehydrateAsync(solution, cancellationToken).ConfigureAwait(false);
184nonConflictSymbolKeys, cancellationToken).ConfigureAwait(false);
204var renameLocations = await SymbolicRenameLocations.FindLocationsInCurrentProcessAsync(symbol, solution, options, cancellationToken).ConfigureAwait(false);
206renameLocations, newName, nonConflictSymbolKeys, cancellationToken).ConfigureAwait(false);
Rename\RenameUtilities.cs (8)
219symbol.GetOverriddenMember(), solution, cancellationToken).ConfigureAwait(false);
222return await TryGetPropertyFromAccessorOrAnOverrideAsync(originalSourceSymbol, solution, cancellationToken).ConfigureAwait(false);
229symbol, solution, cancellationToken: cancellationToken).ConfigureAwait(false);
233var propertyAccessorOrAnOverride = await TryGetPropertyFromAccessorOrAnOverrideAsync(methodImplementor, solution, cancellationToken).ConfigureAwait(false);
302var symbol = await SymbolFinder.FindSymbolAtPositionAsync(document, position, cancellationToken: cancellationToken).ConfigureAwait(false);
306var definitionSymbol = await FindDefinitionSymbolAsync(symbol, document.Project.Solution, cancellationToken).ConfigureAwait(false);
323symbol, solution, cancellationToken).ConfigureAwait(false);
350var property = await TryGetPropertyFromAccessorOrAnOverrideAsync(bestSymbol, solution, cancellationToken).ConfigureAwait(false);
Rename\SymbolicRenameLocations.cs (7)
63symbol = await RenameUtilities.FindDefinitionSymbolAsync(symbol, solution, cancellationToken).ConfigureAwait(false);
66var originalSymbolResult = await AddLocationsReferenceSymbolsAsync(symbol, solution, cancellationToken).ConfigureAwait(false);
69var overloadsResult = options.RenameOverloads ? await GetOverloadsAsync(symbol, solution, cancellationToken).ConfigureAwait(false) :
79cancellationToken).ConfigureAwait(false);
119overloadsResult.Add(await AddLocationsReferenceSymbolsAsync(overloadedSymbol, solution, cancellationToken).ConfigureAwait(false));
131[symbol], solution, cancellationToken).ConfigureAwait(false);
136await ReferenceProcessing.GetRenamableDefinitionLocationsAsync(referencedSymbol.Definition, symbol, solution, cancellationToken).ConfigureAwait(false));
Rename\SymbolicRenameLocations.ReferenceProcessing.cs (7)
93if (await IsPropertyAccessorOrAnOverrideAsync(referencedSymbol, solution, cancellationToken).ConfigureAwait(false) ||
94await IsPropertyAccessorOrAnOverrideAsync(originalSymbol, solution, cancellationToken).ConfigureAwait(false))
139symbol, solution, cancellationToken).ConfigureAwait(false);
163var shouldIncludeSymbol = await ShouldIncludeSymbolAsync(referencedSymbol, originalSymbol, solution, false, cancellationToken).ConfigureAwait(false);
187var isRenamableAccessor = await IsPropertyAccessorOrAnOverrideAsync(referencedSymbol, solution, cancellationToken).ConfigureAwait(false);
251var shouldIncludeSymbol = await ShouldIncludeSymbolAsync(referencedSymbol, originalSymbol, solution, true, cancellationToken).ConfigureAwait(false);
316isRenamableAccessor: await IsPropertyAccessorOrAnOverrideAsync(referencedSymbol, solution, cancellationToken).ConfigureAwait(false)));
Simplification\Simplifier.cs (8)
161return await ReduceAsync(document, root.FullSpan, optionSet, cancellationToken).ConfigureAwait(false);
168return await ReduceAsync(document, root.FullSpan, options, cancellationToken).ConfigureAwait(false);
189return await ReduceAsync(document, root.GetAnnotatedNodesAndTokens(annotation).Select(t => t.FullSpan), optionSet, cancellationToken).ConfigureAwait(false);
196return await ReduceAsync(document, root.GetAnnotatedNodesAndTokens(annotation).Select(t => t.FullSpan), options, cancellationToken).ConfigureAwait(false);
234var options = await GetOptionsAsync(document, optionSet, cancellationToken).ConfigureAwait(false);
237document, spans.ToImmutableArrayOrEmpty(), options, reducers: default, cancellationToken).ConfigureAwait(false);
251reducers, cancellationToken).ConfigureAwait(false);
257optionSet ??= await document.GetOptionsAsync(cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
Workspace\Solution\SolutionCompilationState.RegularCompilationTracker.cs (25)
238var finalState = await GetOrBuildFinalStateAsync(compilationState, cancellationToken: cancellationToken).ConfigureAwait(false);
267return await BuildFinalStateAsync().ConfigureAwait(false);
304var collapsedInProgressState = await CollapseInProgressStateAsync(expandedInProgressState).ConfigureAwait(false);
305return await FinalizeCompilationAsync(collapsedInProgressState).ConfigureAwait(false);
366var hasSourceGenerators = await compilationState.HasSourceGeneratorsAsync(this.ProjectState.Id, cancellationToken).ConfigureAwait(false);
376await ApplyFirstTransformationAsync(currentState, hasSourceGenerators).ConfigureAwait(false);
423compilationWithoutGeneratedDocuments = await translationAction.TransformCompilationAsync(compilationWithoutGeneratedDocuments, cancellationToken).ConfigureAwait(false);
432staleCompilationWithGeneratedDocuments = await translationAction.TransformCompilationAsync(staleCompilationWithGeneratedDocuments, cancellationToken).ConfigureAwait(false);
455return await FinalizeCompilationWorkerAsync(inProgressState).ConfigureAwait(false);
517projectReference.ProjectId, cancellationToken).ConfigureAwait(false);
538projectReference, this.ProjectState, includeCrossLanguage: true, cancellationToken).ConfigureAwait(false);
550projectReference, this.ProjectState, includeCrossLanguage: false, cancellationToken).ConfigureAwait(false);
563projectReference, this.ProjectState, includeCrossLanguage: true, cancellationToken).ConfigureAwait(false);
589cancellationToken).ConfigureAwait(false);
682compilationState, cancellationToken: cancellationToken).ConfigureAwait(false);
860if (!await compilationState.HasSourceGeneratorsAsync(this.ProjectState.Id, cancellationToken).ConfigureAwait(false))
864compilationState, cancellationToken: cancellationToken).ConfigureAwait(false);
871if (!await compilationState.HasSourceGeneratorsAsync(this.ProjectState.Id, cancellationToken).ConfigureAwait(false))
875compilationState, cancellationToken: cancellationToken).ConfigureAwait(false);
898if (!await compilationState.HasSourceGeneratorsAsync(this.ProjectState.Id, cancellationToken).ConfigureAwait(false))
902compilationState, cancellationToken).ConfigureAwait(false);
1043var docVersion = await projectState.GetLatestDocumentVersionAsync(cancellationToken).ConfigureAwait(false);
1052var dependentProjectVersion = await compilationState.GetDependentVersionAsync(dependentProjectReference.ProjectId, cancellationToken).ConfigureAwait(false);
1081var version = await projectState.GetSemanticVersionAsync(cancellationToken).ConfigureAwait(false);
1090dependentProjectReference.ProjectId, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.Workspaces.MSBuild (35)
MSBuild\MSBuildProjectLoader.Worker.cs (10)
115result = await doFunc().ConfigureAwait(false);
153var projectFileInfos = await LoadProjectInfosFromPathAsync(absoluteProjectPath, _requestedProjectOptions, cancellationToken).ConfigureAwait(false);
179var (buildHost, actualBuildHostKind) = await _buildHostProcessManager.GetBuildHostWithFallbackAsync(preferredBuildHostKind, projectPath, cancellationToken).ConfigureAwait(false);
185).ConfigureAwait(false);
188var diagnosticItems = await projectFile.GetDiagnosticLogItemsAsync(cancellationToken).ConfigureAwait(false);
201).ConfigureAwait(false);
213diagnosticItems = await projectFile.GetDiagnosticLogItemsAsync(cancellationToken).ConfigureAwait(false);
230var projectFileInfos = await LoadProjectFileInfosAsync(projectPath, reportingOptions, cancellationToken).ConfigureAwait(false);
261var projectInfo = await CreateProjectInfoAsync(fileInfo, id, addDiscriminator, cancellationToken).ConfigureAwait(false);
366var resolvedReferences = await ResolveReferencesAsync(projectId, projectFileInfo, commandLineArgs, cancellationToken).ConfigureAwait(false);
MSBuild\MSBuildProjectLoader.Worker_ResolveReferences.cs (8)
219await VerifyUnloadableProjectOutputExistsAsync(projectReferencePath, builder, cancellationToken).ConfigureAwait(false))
227await VerifyProjectOutputExistsAsync(projectReferencePath, builder, cancellationToken).ConfigureAwait(false))
233if (await TryLoadAndAddReferenceAsync(id, projectReferencePath, aliases, builder, cancellationToken).ConfigureAwait(false))
241_ = await LoadProjectInfosFromPathAsync(projectReferencePath, _discoveredProjectOptions, cancellationToken).ConfigureAwait(false);
270var projectReferenceInfos = await LoadProjectInfosFromPathAsync(projectReferencePath, _discoveredProjectOptions, cancellationToken).ConfigureAwait(false);
343var buildHost = await _buildHostProcessManager.GetBuildHostWithFallbackAsync(projectPath, cancellationToken).ConfigureAwait(false);
344var outputFilePath = await buildHost.TryGetProjectOutputPathAsync(projectPath, cancellationToken).ConfigureAwait(false);
353var projectFileInfos = await LoadProjectFileInfosAsync(projectPath, DiagnosticReportingOptions.IgnoreAll, cancellationToken).ConfigureAwait(false);
Microsoft.CodeAnalysis.Workspaces.MSBuild.BuildHost (17)
Microsoft.CodeAnalysis.Workspaces.Test.Utilities (2)
Microsoft.CodeAnalysis.Workspaces.UnitTests (16)
FindAllDeclarationsTests.cs (13)
95var declarations = await SymbolFinder.FindDeclarationsAsync(project, searchTerm, ignoreCase).ConfigureAwait(false);
261var declarations = await SymbolFinder.FindSourceDeclarationsAsync(project, searchTerm, ignoreCase).ConfigureAwait(false);
366var declarations = await SymbolFinder.FindSourceDeclarationsAsync(solution, searchTerm, ignoreCase).ConfigureAwait(false);
417var declarations = await SymbolFinder.FindSourceDeclarationsAsync(project, str => str.Contains("Test")).ConfigureAwait(false);
425var declarations = await SymbolFinder.FindSourceDeclarationsAsync(project, str => true).ConfigureAwait(false);
433var declarations = await SymbolFinder.FindSourceDeclarationsAsync(project, str => false).ConfigureAwait(false);
484var declarations = await SymbolFinder.FindSourceDeclarationsAsync(solution, str => str.Contains("Test")).ConfigureAwait(false);
492var declarations = await SymbolFinder.FindSourceDeclarationsAsync(solution, str => true).ConfigureAwait(false);
500var declarations = await SymbolFinder.FindSourceDeclarationsAsync(solution, str => false).ConfigureAwait(false);
551var declarations = await SymbolFinder.FindSourceDeclarationsWithPatternAsync(project, "test").ConfigureAwait(false);
564var declarations = await SymbolFinder.FindSourceDeclarationsWithPatternAsync(project, pattern).ConfigureAwait(false);
615var declarations = await SymbolFinder.FindSourceDeclarationsWithPatternAsync(solution, "test").ConfigureAwait(false);
628var declarations = await SymbolFinder.FindSourceDeclarationsWithPatternAsync(solution, pattern).ConfigureAwait(false);
Microsoft.CommonLanguageServerProtocol.Framework.Package (10)
Microsoft.DotNet.Arcade.Sdk (1)
Microsoft.DotNet.Build.Tasks.Feed (6)
Microsoft.DotNet.Deployment.Tasks.Links (1)
Microsoft.DotNet.Helix.Client (80)
Microsoft.DotNet.Helix.JobSender (2)
Microsoft.DotNet.Helix.Sdk (6)
Microsoft.DotNet.Internal.SymbolHelper (12)
SymbolUploadHelper.cs (10)
125return await RunSymbolCommand("help", ".", logger).ConfigureAwait(false);
141return await RunSymbolCommand(arguments, ".", logger).ConfigureAwait(false);
162return await AddDirectoryCore(name!, pathToAdd, manifestPath: null, logger).ConfigureAwait(false);
188return await AddPackageToRequestCore(name!, packagePath, logger).ConfigureAwait(false);
209result = await AddPackageToRequestCore(name!, package, logger).ConfigureAwait(false);
231return await RunSymbolCommand(arguments, ".", logger).ConfigureAwait(false);
249return await RunSymbolCommand(arguments, ".", logger).ConfigureAwait(false);
262return await RunSymbolCommand(arguments, pathToAdd, logger).ConfigureAwait(false);
317return await AddDirectoryCore(name, packageExtractDir, manifest, logger).ConfigureAwait(false);
469Task alertedTask = await Task.WhenAny(outputAvailable, errorAvailable).ConfigureAwait(false);
Microsoft.Extensions.AI.Abstractions (4)
Microsoft.Extensions.AI.AzureAIInference (4)
Microsoft.Extensions.AI.Evaluation (4)
Microsoft.Extensions.AI.Evaluation.Console (2)
Microsoft.Extensions.AI.Evaluation.NLP (1)
Microsoft.Extensions.AI.Evaluation.Quality (2)
Microsoft.Extensions.AI.Evaluation.Reporting (6)
Microsoft.Extensions.AI.Evaluation.Reporting.Azure (15)
Microsoft.Extensions.AI.Evaluation.Safety (7)
Microsoft.Extensions.AI.Integration.Tests (8)
Microsoft.Extensions.AI.Ollama (5)
Microsoft.Extensions.AI.OpenAI (9)
Microsoft.Extensions.Caching.Abstractions (2)
Microsoft.Extensions.Caching.Hybrid (5)
Microsoft.Extensions.Caching.SqlServer (9)
Microsoft.Extensions.Caching.StackExchangeRedis (9)
Microsoft.Extensions.Diagnostics.HealthChecks (3)
Microsoft.Extensions.Diagnostics.Probes (1)
Microsoft.Extensions.Hosting.WindowsServices (1)
Microsoft.Extensions.Http (3)
Microsoft.Extensions.Http.Diagnostics (4)
Microsoft.Extensions.Http.Diagnostics.PerformanceTests (48)
Microsoft.Extensions.Http.Diagnostics.Tests (5)
Microsoft.Extensions.Http.Polly (2)
Microsoft.Extensions.Http.Resilience (1)
Microsoft.Extensions.Http.Resilience.PerformanceTests (1)
Microsoft.Extensions.Identity.Core (141)
UserManager.cs (92)
480var result = await ValidateUserAsync(user).ConfigureAwait(false);
492return await Store.CreateAsync(user, CancellationToken).ConfigureAwait(false);
553var user = await Store.FindByNameAsync(userName, CancellationToken).ConfigureAwait(false);
565user = await Store.FindByNameAsync(oldKey, CancellationToken).ConfigureAwait(false);
592var result = await UpdatePasswordHash(passwordStore, user, password).ConfigureAwait(false);
597return await CreateAsync(user).ConfigureAwait(false);
637var normalizedName = NormalizeName(await GetUserNameAsync(user).ConfigureAwait(false));
651return await Store.GetUserNameAsync(user, CancellationToken).ConfigureAwait(false);
667return await UpdateUserAsync(user).ConfigureAwait(false);
678return await Store.GetUserIdAsync(user, CancellationToken).ConfigureAwait(false);
699var result = await VerifyPasswordAsync(passwordStore, user, password).ConfigureAwait(false);
702await UpdatePasswordHash(passwordStore, user, password, validatePassword: false).ConfigureAwait(false);
703await UpdateUserAsync(user).ConfigureAwait(false);
747var hash = await passwordStore.GetPasswordHashAsync(user, CancellationToken).ConfigureAwait(false);
753var result = await UpdatePasswordHash(passwordStore, user, password).ConfigureAwait(false);
758return await UpdateUserAsync(user).ConfigureAwait(false);
778if (await VerifyPasswordAsync(passwordStore, user, currentPassword).ConfigureAwait(false) != PasswordVerificationResult.Failed)
780var result = await UpdatePasswordHash(passwordStore, user, newPassword).ConfigureAwait(false);
785return await UpdateUserAsync(user).ConfigureAwait(false);
805await UpdatePasswordHash(passwordStore, user, null, validatePassword: false).ConfigureAwait(false);
806return await UpdateUserAsync(user).ConfigureAwait(false);
821var hash = await store.GetPasswordHashAsync(user, CancellationToken).ConfigureAwait(false);
839var stamp = await securityStore.GetSecurityStampAsync(user, CancellationToken).ConfigureAwait(false);
866return await UpdateUserAsync(user).ConfigureAwait(false);
899if (!await VerifyUserTokenAsync(user, Options.Tokens.PasswordResetTokenProvider, ResetPasswordTokenPurpose, token).ConfigureAwait(false))
903var result = await UpdatePasswordHash(user, newPassword, validatePassword: true).ConfigureAwait(false);
908return await UpdateUserAsync(user).ConfigureAwait(false);
949return await UpdateUserAsync(user).ConfigureAwait(false);
968var existingUser = await FindByLoginAsync(login.LoginProvider, login.ProviderKey).ConfigureAwait(false);
975return await UpdateUserAsync(user).ConfigureAwait(false);
990return await loginStore.GetLoginsAsync(user, CancellationToken).ConfigureAwait(false);
1028return await UpdateUserAsync(user).ConfigureAwait(false);
1050return await UpdateUserAsync(user).ConfigureAwait(false);
1088return await UpdateUserAsync(user).ConfigureAwait(false);
1103return await claimStore.GetClaimsAsync(user, CancellationToken).ConfigureAwait(false);
1122if (await userRoleStore.IsInRoleAsync(user, normalizedRole, CancellationToken).ConfigureAwait(false))
1127return await UpdateUserAsync(user).ConfigureAwait(false);
1149if (await userRoleStore.IsInRoleAsync(user, normalizedRole, CancellationToken).ConfigureAwait(false))
1155return await UpdateUserAsync(user).ConfigureAwait(false);
1174if (!await userRoleStore.IsInRoleAsync(user, normalizedRole, CancellationToken).ConfigureAwait(false))
1179return await UpdateUserAsync(user).ConfigureAwait(false);
1219if (!await userRoleStore.IsInRoleAsync(user, normalizedRole, CancellationToken).ConfigureAwait(false))
1225return await UpdateUserAsync(user).ConfigureAwait(false);
1238return await userRoleStore.GetRolesAsync(user, CancellationToken).ConfigureAwait(false);
1255return await userRoleStore.IsInRoleAsync(user, NormalizeName(role), CancellationToken).ConfigureAwait(false);
1268return await store.GetEmailAsync(user, CancellationToken).ConfigureAwait(false);
1289return await UpdateUserAsync(user).ConfigureAwait(false);
1308var user = await store.FindByEmailAsync(email, CancellationToken).ConfigureAwait(false);
1320user = await store.FindByEmailAsync(oldKey, CancellationToken).ConfigureAwait(false);
1341var email = await GetEmailAsync(user).ConfigureAwait(false);
1374if (!await VerifyUserTokenAsync(user, Options.Tokens.EmailConfirmationTokenProvider, ConfirmEmailTokenPurpose, token).ConfigureAwait(false))
1379return await UpdateUserAsync(user).ConfigureAwait(false);
1396return await store.GetEmailConfirmedAsync(user, CancellationToken).ConfigureAwait(false);
1429if (!await VerifyUserTokenAsync(user, Options.Tokens.ChangeEmailTokenProvider, GetChangeEmailTokenPurpose(newEmail), token).ConfigureAwait(false))
1437return await UpdateUserAsync(user).ConfigureAwait(false);
1450return await store.GetPhoneNumberAsync(user, CancellationToken).ConfigureAwait(false);
1471return await UpdateUserAsync(user).ConfigureAwait(false);
1491if (!await VerifyChangePhoneNumberTokenAsync(user, token, phoneNumber).ConfigureAwait(false))
1499return await UpdateUserAsync(user).ConfigureAwait(false);
1575var result = await provider.ValidateAsync(purpose, token, this, user).ConfigureAwait(false);
1636if (await f.Value.CanGenerateTwoFactorTokenAsync(this, user).ConfigureAwait(false))
1664var result = await provider.ValidateAsync("TwoFactor", token, this, user).ConfigureAwait(false);
1707return await store.GetTwoFactorEnabledAsync(user, CancellationToken).ConfigureAwait(false);
1727return await UpdateUserAsync(user).ConfigureAwait(false);
1744if (!await store.GetLockoutEnabledAsync(user, CancellationToken).ConfigureAwait(false))
1748var lockoutTime = await store.GetLockoutEndDateAsync(user, CancellationToken).ConfigureAwait(false);
1768return await UpdateUserAsync(user).ConfigureAwait(false);
1783return await store.GetLockoutEnabledAsync(user, CancellationToken).ConfigureAwait(false);
1799return await store.GetLockoutEndDateAsync(user, CancellationToken).ConfigureAwait(false);
1814if (!await store.GetLockoutEnabledAsync(user, CancellationToken).ConfigureAwait(false))
1820return await UpdateUserAsync(user).ConfigureAwait(false);
1837var count = await store.IncrementAccessFailedCountAsync(user, CancellationToken).ConfigureAwait(false);
1840return await UpdateUserAsync(user).ConfigureAwait(false);
1846return await UpdateUserAsync(user).ConfigureAwait(false);
1860if (await GetAccessFailedCountAsync(user).ConfigureAwait(false) == 0)
1865return await UpdateUserAsync(user).ConfigureAwait(false);
1879return await store.GetAccessFailedCountAsync(user, CancellationToken).ConfigureAwait(false);
1951return await UpdateUserAsync(user).ConfigureAwait(false);
1970return await UpdateUserAsync(user).ConfigureAwait(false);
1998return await UpdateAsync(user).ConfigureAwait(false);
2027var update = await UpdateAsync(user).ConfigureAwait(false);
2124var success = await store.RedeemCodeAsync(user, code, CancellationToken).ConfigureAwait(false);
2127return await UpdateAsync(user).ConfigureAwait(false);
2160return await UpdateUserAsync(user).ConfigureAwait(false);
2230return await UpdateUserAsync(user).ConfigureAwait(false);
2297return Encoding.Unicode.GetBytes(await GetSecurityStampAsync(user).ConfigureAwait(false));
2324var validate = await ValidatePasswordAsync(user, newPassword).ConfigureAwait(false);
2405var stamp = await GetSecurityStampAsync(user).ConfigureAwait(false);
2414var result = await v.ValidateAsync(this, user).ConfigureAwait(false);
2445var result = await v.ValidateAsync(this, user, password).ConfigureAwait(false);
2475var result = await ValidateUserAsync(user).ConfigureAwait(false);
2482return await Store.UpdateAsync(user, CancellationToken).ConfigureAwait(false);
Microsoft.Extensions.Identity.Stores (7)
UserStoreBase.cs (7)
431var userLogin = await FindUserLoginAsync(loginProvider, providerKey, cancellationToken).ConfigureAwait(false);
434return await FindUserAsync(userLogin.UserId, cancellationToken).ConfigureAwait(false);
835var token = await FindTokenAsync(user, loginProvider, name, cancellationToken).ConfigureAwait(false);
860var entry = await FindTokenAsync(user, loginProvider, name, cancellationToken).ConfigureAwait(false);
881var entry = await FindTokenAsync(user, loginProvider, name, cancellationToken).ConfigureAwait(false);
920var mergedCodes = await GetTokenAsync(user, InternalLoginProvider, RecoveryCodeTokenName, cancellationToken).ConfigureAwait(false) ?? "";
974var mergedCodes = await GetTokenAsync(user, InternalLoginProvider, RecoveryCodeTokenName, cancellationToken).ConfigureAwait(false) ?? "";
Microsoft.Extensions.Logging.AzureAppServices (3)
Microsoft.Extensions.ML (1)
Microsoft.Extensions.ServiceDiscovery (2)
Microsoft.Extensions.ServiceDiscovery.Yarp (2)
Microsoft.Gen.ComplianceReports.Unit.Tests (15)
Microsoft.Gen.ContextualOptions.Unit.Tests (19)
Microsoft.Gen.Logging.Unit.Tests (16)
Microsoft.Gen.MetadataExtractor.Unit.Tests (15)
Microsoft.Gen.Metrics.Unit.Tests (15)
Microsoft.Gen.MetricsReports.Unit.Tests (15)
Microsoft.Interop.ComInterfaceGenerator (13)
Microsoft.Interop.LibraryImportGenerator (27)
Microsoft.Maui (3)
Microsoft.Maui.Controls (17)
Internals\ImageParser.cs (12)
123 int bytesRead = await ReadAsync(_blockBuffer, _currentBlockSize).ConfigureAwait(false);
147 await ReadAsync(_blockBuffer, _currentBlockSize).ConfigureAwait(false);
210 int bytesRead = await stream.ReadAsync(_colorData, toRead).ConfigureAwait(false);
309 GlobalColorTable = await GIFColorTable.CreateColorTableAsync(stream, GlobalColorTableSize(flags)).ConfigureAwait(false);
454 int blockSize = await stream.ReadBlockAsync().ConfigureAwait(false);
466 blockSize = await stream.ReadBlockAsync().ConfigureAwait(false);
472 var blockSize = await stream.ReadBlockAsync().ConfigureAwait(false);
495 ColorTable = await GIFColorTable.CreateColorTableAsync(stream, LocalColorTableSize(flags)).ConfigureAwait(false);
774 count = await stream.ReadBlockAsync().ConfigureAwait(false);
875 GIFHeader header = await GIFHeader.CreateHeaderAsync(reader, skipTypeIdentifier).ConfigureAwait(false);
877 currentBitmap = await GIFBitmap.CreateBitmapAsync(reader, header, decoder, previousBitmap, ignoreImageData).ConfigureAwait(false);
882 currentBitmap = await GIFBitmap.CreateBitmapAsync(reader, header, decoder, previousBitmap, ignoreImageData).ConfigureAwait(false);
Microsoft.Maui.Essentials (3)
Microsoft.Maui.Maps (2)
Microsoft.ML.AutoML.Tests (2)
Microsoft.ML.Core (2)
Microsoft.ML.InternalCodeAnalyzer (2)
Microsoft.ML.Samples (5)
Microsoft.ML.Samples.GPU (5)
Microsoft.ML.SamplesUtils (1)
Microsoft.ML.Tokenizers (7)
Microsoft.VisualStudio.LanguageServices (221)
CodeCleanup\AbstractCodeCleanUpFixer.cs (7)
63context).ConfigureAwait(false);
101context).ConfigureAwait(false);
129var newDocument = await FixDocumentAsync(document, context.EnabledFixIds, progress, cancellationToken).ConfigureAwait(true);
132context).ConfigureAwait(false);
163var newDoc = await FixDocumentAsync(document, context.EnabledFixIds, progress, cancellationToken).ConfigureAwait(true);
185var solution = await applyFixAsync(progress, cancellationToken).ConfigureAwait(true);
224var fixedDocument = await FixDocumentAsync(document, enabledFixIds, CodeAnalysisProgress.None, cancellationToken).ConfigureAwait(false);
Library\ObjectBrowser\ObjectList.cs (9)
412return await IsExpandableTypeAsync(index, cancellationToken).ConfigureAwait(true);
426this.LibraryManager.Workspace, cancellationToken).ConfigureAwait(true);
503project, lookInReferences, cancellationToken).ConfigureAwait(true);
505listKind, flags, pobSrch, projectAndAssemblySet, cancellationToken).ConfigureAwait(true);
509this.LibraryManager.Workspace, cancellationToken).ConfigureAwait(true);
573symbolListItem, useExpandedHierarchy: IsClassView(), cancellationToken).ConfigureAwait(true);
684var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(true);
752var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
755await this.LibraryManager.Workspace.TryGoToDefinitionAsync(symbol, project, cancellationToken).ConfigureAwait(false);
Packaging\PackageInstallerServiceFactory.cs (11)
286progressTracker, cancellationToken).ConfigureAwait(false);
317var installedPackagesMap = await GetInstalledPackagesMapAsync(nugetService, projectGuid, cancellationToken).ConfigureAwait(false);
334installedPackagesMap = await GetInstalledPackagesMapAsync(nugetService, projectGuid, cancellationToken).ConfigureAwait(false);
342}, cancellationToken).ConfigureAwait(false);
389var installedPackagesMap = await GetInstalledPackagesMapAsync(nugetService, projectGuid, cancellationToken).ConfigureAwait(false);
403}, cancellationToken).ConfigureAwait(false);
492}, cancellationToken).ConfigureAwait(false);
502var serviceContainer = await _brokeredServiceContainer.GetValueOrNullAsync(cancellationToken).ConfigureAwait(false);
562nugetService, projectGuid, cancellationToken).ConfigureAwait(false);
580var installedPackagesMap = await GetInstalledPackagesMapAsync(nugetService, projectGuid, cancellationToken).ConfigureAwait(false);
592var installedPackagesResult = await nugetService.GetInstalledPackagesAsync(projectGuid, cancellationToken).ConfigureAwait(false);
TableDataSource\Suppression\VisualStudioSuppressionFixService.cs (12)
67var errorList = await serviceProvider.GetServiceAsync<SVsErrorList, IErrorList>(throwOnFailure: false, cancellationToken).ConfigureAwait(false);
82var diagnosticsToFix = await GetDiagnosticsToFixAsync(selectedEntriesOnly: false, isAddSuppression: true).ConfigureAwait(true);
104showPreviewChangesDialog: true).ConfigureAwait(true);
122showPreviewChangesDialog: true).ConfigureAwait(true);
158? await _suppressionStateService.GetSelectedItemsAsync(isAddSuppression, cancellationToken).ConfigureAwait(true)
163}, GetFixTitle(isAddSuppression), GetWaitDialogMessage(isAddSuppression)).ConfigureAwait(true);
179var diagnosticsToFix = await GetDiagnosticsToFixAsync(selectedEntriesOnly, isAddSuppression).ConfigureAwait(true);
225diagnosticsToFix, shouldFixInProject, filterStaleDiagnostics, cancellationToken).ConfigureAwait(false);
230: await GetProjectDiagnosticsToFixAsync(diagnosticsToFix, shouldFixInProject, filterStaleDiagnostics, cancellationToken).ConfigureAwait(false);
278cancellationToken).ConfigureAwait(false);
303cancellationToken).ConfigureAwait(false);
346cancellationToken).ConfigureAwait(false);
Venus\ContainedDocument.DocumentServiceProvider.cs (4)
77var textChanges = (await newDocument.GetTextChangesAsync(oldDocument, cancellationToken).ConfigureAwait(false)).ToImmutableArray();
78var mappedSpanResults = await MapSpansAsync(oldDocument, textChanges.Select(tc => tc.Span), CancellationToken.None).ConfigureAwait(false);
167var classifiedSpansOnContent = await GetClassifiedSpansOnContentAsync(document, roslynSnapshot, contentSpanOnPrimarySnapshot.Value, classificationOptions, cancellationToken).ConfigureAwait(false);
200document, fixedUpSpan.Span.ToTextSpan(), options, includeAdditiveSpans: false, cancellationToken).ConfigureAwait(false);
Workspace\VisualStudioDocumentNavigationService.cs (15)
64documentId, vsTextSpan, cancellationToken).ConfigureAwait(false);
96documentId, vsTextSpan, cancellationToken).ConfigureAwait(false);
102if (!await this.CanNavigateToSpanAsync(workspace, documentId, textSpan, allowInvalidSpan, cancellationToken).ConfigureAwait(false))
110cancellationToken).ConfigureAwait(false);
116if (!await this.CanNavigateToPositionAsync(workspace, documentId, position, virtualSpace, allowInvalidPosition, cancellationToken).ConfigureAwait(false))
124cancellationToken).ConfigureAwait(false);
164workspace, documentId, getTextSpanForMappingAsync, getVsTextSpan, getVsTextSpanForMapping, cancellationToken).ConfigureAwait(true);
174return await callback(cancellationToken).ConfigureAwait(true);
202await getTextSpanForMappingAsync(generatedDocument).ConfigureAwait(false));
212await getTextSpanForMappingAsync(document).ConfigureAwait(false),
213cancellationToken).ConfigureAwait(false);
234workspace, document, mappedSpan, cancellationToken).ConfigureAwait(false);
273_threadingContext, documentId, cancellationToken).ConfigureAwait(false);
281text.Container.GetTextBuffer(), vsTextSpan, cancellationToken).ConfigureAwait(false);
415_threadingContext, documentId, cancellationToken).ConfigureAwait(false);
Workspace\VisualStudioSymbolNavigationService.cs (6)
103var compilation = await project.GetCompilationAsync(cancellationToken).ConfigureAwait(false);
121return await GetNavigableLocationForMetadataAsync(project, symbol, cancellationToken).ConfigureAwait(false);
188var result = await TryGetNavigationAPIRequiredArgumentsAsync(definitionItem, rqName, cancellationToken).ConfigureAwait(true);
207return await GetExternalNavigationLocationForSpecificSymbolAsync(definitionItem, rqName1, cancellationToken).ConfigureAwait(false) ??
208await GetExternalNavigationLocationForSpecificSymbolAsync(definitionItem, rqName2, cancellationToken).ConfigureAwait(false);
218definitionItem, rqName, cancellationToken).ConfigureAwait(false);
Microsoft.VisualStudio.LanguageServices.CodeLens (3)
Microsoft.VisualStudio.LanguageServices.CSharp (18)
Microsoft.VisualStudio.LanguageServices.DevKit (2)
Microsoft.VisualStudio.LanguageServices.LiveShare (8)
Microsoft.VisualStudio.LanguageServices.UnitTests (6)
Microsoft.VisualStudio.LanguageServices.VisualBasic (5)
Microsoft.VisualStudio.LanguageServices.Xaml (22)
Implementation\LanguageServer\Handler\Definitions\GoToDefinitionHandler.cs (4)
70var definitions = await xamlGoToDefinitionService.GetDefinitionsAsync(document, position, cancellationToken).ConfigureAwait(false);
78foreach (var location in await this.GetLocationsAsync(definition, document, solution, cancellationToken).ConfigureAwait(false))
97locations.AddIfNotNull(await GetSourceDefinitionLocationAsync(sourceDefinition, solution, cancellationToken).ConfigureAwait(false));
101locations.AddRange(await GetSymbolDefinitionLocationsAsync(symbolDefinition, document, solution, _metadataAsSourceFileService, _globalOptions, cancellationToken).ConfigureAwait(false));
MSBuild (1)
Replay (12)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
Roslyn.Compilers.Extension (8)
Roslyn.Diagnostics.Analyzers (110)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
Roslyn.Diagnostics.CSharp.Analyzers (13)
Roslyn.Diagnostics.VisualBasic.Analyzers (1)
Roslyn.VisualStudio.DiagnosticsWindow (6)
Roslyn.VisualStudio.Next.UnitTests (10)
RunTests (3)
Sockets.BindTests (3)
Sockets.FunctionalTests (3)
System.Data.Common (6)
System.IO.Compression (29)
System\IO\Compression\ZipArchiveEntry.Async.cs (18)
30return await OpenInReadModeAsync(checkOpenable: true, cancellationToken).ConfigureAwait(false);
36return await OpenInUpdateModeAsync(cancellationToken).ConfigureAwait(false);
48if (!await ZipLocalFileHeader.TrySkipBlockAsync(_archive.ArchiveStream, cancellationToken).ConfigureAwait(false))
68Stream decompressor = await OpenInReadModeAsync(false, cancellationToken).ConfigureAwait(false);
151Debug.Assert(await GetIsOpenableAsync(false, true, cancellationToken).ConfigureAwait(false));
157(_lhUnknownExtraFields, _lhTrailingExtraFieldData) = await ZipLocalFileHeader.GetExtraFieldsAsync(_archive.ArchiveStream, cancellationToken).ConfigureAwait(false);
165Debug.Assert(await GetIsOpenableAsync(false, true, cancellationToken).ConfigureAwait(false));
171_archive.ArchiveStream.Seek(await GetOffsetOfCompressedDataAsync(cancellationToken).ConfigureAwait(false), SeekOrigin.Begin);
175await ZipHelper.ReadBytesAsync(_archive.ArchiveStream, _compressedBytes[i], maxSingleBufferSize, cancellationToken).ConfigureAwait(false);
177await ZipHelper.ReadBytesAsync(_archive.ArchiveStream, _compressedBytes[_compressedBytes.Length - 1], (int)(_compressedSize % maxSingleBufferSize), cancellationToken).ConfigureAwait(false);
184(bool result, _) = await IsOpenableAsync(needToUncompress, needToLoadIntoMemory, cancellationToken).ConfigureAwait(false);
191(bool openable, string? message) = await IsOpenableAsync(needToUncompress, needToLoadIntoMemory, cancellationToken).ConfigureAwait(false);
203await GetOffsetOfCompressedDataAsync(cancellationToken).ConfigureAwait(false));
218Stream uncompressedData = await GetUncompressedDataAsync(cancellationToken).ConfigureAwait(false);
244if (!await ZipLocalFileHeader.TrySkipBlockAsync(_archive.ArchiveStream, cancellationToken).ConfigureAwait(false))
251long offsetOfCompressedData = await GetOffsetOfCompressedDataAsync(cancellationToken).ConfigureAwait(false);
315await WriteLocalFileHeaderAsync(isEmptyFile: _uncompressedSize == 0, forceWrite: true, cancellationToken).ConfigureAwait(false);
333await WriteLocalFileHeaderAsync(isEmptyFile: _uncompressedSize == 0, forceWrite: forceWrite, cancellationToken).ConfigureAwait(false);
System.IO.Compression.ZipFile (8)
System\IO\Compression\ZipFile.Create.Async.cs (4)
165return await ZipArchive.CreateAsync(fs, mode, leaveOpen: false, entryNameEncoding: entryNameEncoding, cancellationToken).ConfigureAwait(false);
437ZipArchive archive = await OpenAsync(destinationArchiveFileName, ZipArchiveMode.Create, entryNameEncoding, cancellationToken).ConfigureAwait(false);
451ZipArchive archive = await ZipArchive.CreateAsync(destination, ZipArchiveMode.Create, leaveOpen: true, entryNameEncoding, cancellationToken).ConfigureAwait(false);
476await ZipFileExtensions.DoCreateEntryFromFileAsync(archive, fullPath, entryName, compressionLevel, cancellationToken).ConfigureAwait(false);
System.Memory.Data (1)
System.Net.Http (32)
System\Net\Http\SocketsHttpHandler\AuthenticationHelper.NtAuth.cs (3)
78HttpResponseMessage response = await InnerSendAsync(request, async, isProxyAuth, connectionPool, connection, cancellationToken).ConfigureAwait(false);
144IPHostEntry result = await Dns.GetHostEntryAsync(authUri.IdnHost, cancellationToken).ConfigureAwait(false);
200response = await InnerSendAsync(request, async, isProxyAuth, connectionPool, connection, cancellationToken).ConfigureAwait(false);
System.Net.Http.Json (3)
System.Net.Mail (20)
System.Net.NameResolution (1)
System.Net.NetworkInformation (1)
System.Net.Ping (3)
System.Net.Quic (1)
System.Net.Requests (7)
System.Net.Security (1)
System.Net.Sockets (5)
System.Net.WebClient (2)
System.Net.WebSockets (2)
System.Net.WebSockets.Client (1)
System.Private.CoreLib (4)
System.Private.DataContractSerialization (3)
System.Private.Xml (380)
System\Xml\Core\ReadContentAsBinaryHelperAsync.cs (24)
28if (!await InitAsync().ConfigureAwait(false))
38return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
54return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
72if (!await InitAsync().ConfigureAwait(false))
82return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
98return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
116if (!await InitOnElementAsync().ConfigureAwait(false))
128return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
142return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
160if (!await InitOnElementAsync().ConfigureAwait(false))
172return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
186return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
193while (await MoveToNextContentNodeAsync(true).ConfigureAwait(false))
202await _reader.ReadAsync().ConfigureAwait(false);
212if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
228await _reader.ReadAsync().ConfigureAwait(false);
235if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
242await _reader.ReadAsync().ConfigureAwait(false);
278if ((_valueChunkLength = await _reader.ReadValueChunkAsync(_valueChunk!, 0, ChunkSize).ConfigureAwait(false)) == 0)
288string value = await _reader.GetValueAsync().ConfigureAwait(false);
301if (!await MoveToNextContentNodeAsync(true).ConfigureAwait(false))
316int decoded = await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
329await _reader.ReadAsync().ConfigureAwait(false);
367} while (await _reader.ReadAsync().ConfigureAwait(false));
System\Xml\Core\XmlCharCheckingReaderAsync.cs (24)
43if (!await base.reader.ReadAsync().ConfigureAwait(false))
63return await ReadAsync().ConfigureAwait(false);
69return await ReadAsync().ConfigureAwait(false);
75return await ReadAsync().ConfigureAwait(false);
85return await ReadAsync().ConfigureAwait(false);
119CheckCharacters(await base.reader.GetValueAsync().ConfigureAwait(false));
134return await ReadAsync().ConfigureAwait(false);
146return await ReadAsync().ConfigureAwait(false);
161return await ReadAsync().ConfigureAwait(false);
189return await ReadAsync().ConfigureAwait(false);
193CheckWhitespace(await base.reader.GetValueAsync().ConfigureAwait(false));
200CheckWhitespace(await base.reader.GetValueAsync().ConfigureAwait(false));
234return await base.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
247return await base.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
255int readCount = await _readBinaryHelper.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
277return await base.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
290return await base.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
298int readCount = await _readBinaryHelper.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
330return await base.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
343return await base.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
351int readCount = await _readBinaryHelper.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
384return await base.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
397return await base.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
405int readCount = await _readBinaryHelper.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
System\Xml\Core\XmlSubtreeReaderAsync.cs (29)
54if (await reader.ReadAsync().ConfigureAwait(false))
81if (!await FinishReadElementContentAsBinaryAsync().ConfigureAwait(false))
85return await ReadAsync().ConfigureAwait(false);
89if (!await FinishReadContentAsBinaryAsync().ConfigureAwait(false))
93return await ReadAsync().ConfigureAwait(false);
106await ReadAsync().ConfigureAwait(false);
119if (await reader.ReadAsync().ConfigureAwait(false))
160if (await FinishReadElementContentAsBinaryAsync().ConfigureAwait(false))
168if (await FinishReadContentAsBinaryAsync().ConfigureAwait(false))
188object value = await reader.ReadContentAsObjectAsync().ConfigureAwait(false);
204string value = await reader.ReadContentAsStringAsync().ConfigureAwait(false);
220object value = await reader.ReadContentAsAsync(returnType, namespaceResolver).ConfigureAwait(false);
282return await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
293int read = await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
325if (!await InitReadElementContentAsBinaryAsync(State.ReadElementContentAsBase64).ConfigureAwait(false))
332int read = await reader.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
354await ReadAsync().ConfigureAwait(false);
420return await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
431int read = await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
463if (!await InitReadElementContentAsBinaryAsync(State.ReadElementContentAsBinHex).ConfigureAwait(false))
469int read = await reader.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
491await ReadAsync().ConfigureAwait(false);
567if (!await ReadAsync().ConfigureAwait(false) || isEmpty)
579await ReadAsync().ConfigureAwait(false);
595while (await reader.ReadContentAsBase64Async(bytes, 0, 256).ConfigureAwait(false) > 0) ;
599while (await reader.ReadContentAsBinHexAsync(bytes, 0, 256).ConfigureAwait(false) > 0) ;
619return await ReadAsync().ConfigureAwait(false);
629while (await reader.ReadContentAsBase64Async(bytes, 0, 256).ConfigureAwait(false) > 0) ;
633while (await reader.ReadContentAsBinHexAsync(bytes, 0, 256).ConfigureAwait(false) > 0) ;
System\Xml\Core\XmlTextReaderImplAsync.cs (126)
77Stream stream = (Stream)(await _laterInitParam!.inputUriResolver!.GetEntityAsync(_laterInitParam.inputbaseUri!, string.Empty, typeof(Stream)).ConfigureAwait(false));
141await InitTextReaderInputAsync(_reportedBaseUri!, _laterInitParam!.inputTextReader!).ConfigureAwait(false);
287bool result = await task.ConfigureAwait(false);
288return await ReadAsync_SwitchToInteractiveXmlDecl_Helper(result).ConfigureAwait(false);
355while (await _outerReader.ReadAsync().ConfigureAwait(false) && _index > initialDepth) ;
365await _outerReader.ReadAsync().ConfigureAwait(false);
371bool result = await task.ConfigureAwait(false);
382return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
458return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
477if (!await InitReadContentAsBinaryAsync().ConfigureAwait(false))
487return await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
492bool result = await task.ConfigureAwait(false);
503return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
579return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
597if (!await InitReadElementContentAsBinaryAsync().ConfigureAwait(false))
607return await ReadElementContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
733var tuple_1 = await this.ParseNumericCharRefAsync(true, internalSubsetBuilder).ConfigureAwait(false);
750await ParsePIAsync(null).ConfigureAwait(false);
755await ParsePIAsync(sb).ConfigureAwait(false);
811retValue = await PushExternalEntityAsync(entity).ConfigureAwait(false);
850await EatWhitespacesAsync(null).ConfigureAwait(false);
852if (!await ParseXmlDeclarationAsync(true).ConfigureAwait(false))
935await ReadDataAsync().ConfigureAwait(false);
1143return await ReadDataAsync().ConfigureAwait(false);
1173if (await ReadDataAsync().ConfigureAwait(false) == 0)
1203int wsCount = await EatWhitespacesAsync(xmlDeclState == 0 ? null : sb).ConfigureAwait(false);
1273int nameEndPos = await ParseNameAsync().ConfigureAwait(false);
1321await EatWhitespacesAsync(sb).ConfigureAwait(false);
1333await EatWhitespacesAsync(sb).ConfigureAwait(false);
1420if (await ReadDataAsync().ConfigureAwait(false) != 0)
1435if (_ps.isEof || await ReadDataAsync().ConfigureAwait(false) == 0)
1626var tuple_3 = await HandleEntityReferenceAsync(false, EntityExpandType.OnlyGeneral).ConfigureAwait(false);
1641if (await ParseTextAsync().ConfigureAwait(false))
1645return await ParseDocumentContentAsync().ConfigureAwait(false);
1647return await ParseDocumentContentAsync().ConfigureAwait(false);
1678if (await task.ConfigureAwait(false))
1686return await ParseDocumentContentAsync().ConfigureAwait(false);
1692if (await ReadDataAsync().ConfigureAwait(false) != 0)
1694return await ParseDocumentContentAsync().ConfigureAwait(false);
1710return await ParseDocumentContentAsync().ConfigureAwait(false);
1831if (await ReadDataAsync().ConfigureAwait(false) == 0)
1852return await ParseElementContentAsync().ConfigureAwait(false);
1943var tuple_4 = await task.ConfigureAwait(false);
2052if (await ReadDataAsync().ConfigureAwait(false) == 0)
2091if (await ReadDataAsync().ConfigureAwait(false) == 0)
2272if (await ReadDataAsync().ConfigureAwait(false) == 0)
2286var tuple_5 = await ParseQNameAsync().ConfigureAwait(false);
2461var tuple_6 = await ParseQNameAsync().ConfigureAwait(false);
2471var tuple_7 = await ParseQNameAsync().ConfigureAwait(false);
2490await EatWhitespacesAsync(null).ConfigureAwait(false);
2503await EatWhitespacesAsync(null).ConfigureAwait(false);
2570if (await ReadDataAsync().ConfigureAwait(false) != 0)
2702var tuple_8 = await HandleEntityReferenceAsync(true, EntityExpandType.All).ConfigureAwait(false);
2728string entityName = await ParseEntityNameAsync().ConfigureAwait(false);
2751await ParseEntityNameAsync().ConfigureAwait(false);
2821if (await ReadDataAsync().ConfigureAwait(false) == 0)
2972var tuple_10 = await parseTask.ConfigureAwait(false);
3098return await ParseTextAsync_IgnoreNode().ConfigureAwait(false);
3211await task.ConfigureAwait(false);
3380var tuple_14 = await HandleEntityReferenceAsync(false, EntityExpandType.All).ConfigureAwait(false);
3442if (await ZeroEndingStreamAsync(pos).ConfigureAwait(false))
3467if (await ReadDataAsync().ConfigureAwait(false) == 0)
3659while (await MoveToNextContentNodeAsync(true).ConfigureAwait(false)) ;
3672await _outerReader.ReadAsync().ConfigureAwait(false);
3683await EatWhitespacesAsync(null).ConfigureAwait(false);
3684if (_ps.chars[_ps.charPos] == '<' || _ps.charsUsed - _ps.charPos == 0 || await ZeroEndingStreamAsync(_ps.charPos).ConfigureAwait(false))
3692await EatWhitespacesAsync(_stringBuilder).ConfigureAwait(false);
3693if (_ps.chars[_ps.charPos] == '<' || _ps.charsUsed - _ps.charPos == 0 || await ZeroEndingStreamAsync(_ps.charPos).ConfigureAwait(false))
3722_curNode.SetNamedNode(XmlNodeType.EntityReference, await ParseEntityNameAsync().ConfigureAwait(false));
3733if (await ReadDataAsync().ConfigureAwait(false) == 0)
3744var tuple_17 = await ParseNumericCharRefAsync(expandType != EntityExpandType.OnlyGeneral, null).ConfigureAwait(false);
3757charRefEndPos = await ParseNamedCharRefAsync(expandType != EntityExpandType.OnlyGeneral, null).ConfigureAwait(false);
3779endPos = await ParseNameAsync().ConfigureAwait(false);
3799EntityType entType = await HandleGeneralEntityReferenceAsync(entityName, isInAttributeValue, false, entityLinePos).ConfigureAwait(false);
3867await PushExternalEntityAsync(entity).ConfigureAwait(false);
3875await PushExternalEntityAsync(entity).ConfigureAwait(false);
3911int nameEndPos = await ParseNameAsync().ConfigureAwait(false);
3935if (await EatWhitespacesAsync(piInDtdStringBuilder).ConfigureAwait(false) == 0)
3939await ReadDataAsync().ConfigureAwait(false);
3950var tuple_18 = await ParsePIValueAsync().ConfigureAwait(false);
3982tuple_19 = await ParsePIValueAsync().ConfigureAwait(false);
4001tuple_20 = await ParsePIValueAsync().ConfigureAwait(false);
4025if (await ReadDataAsync().ConfigureAwait(false) == 0)
4204var tuple_21 = await ParseCDataOrCommentTupleAsync(type).ConfigureAwait(false);
4220tuple_22 = await ParseCDataOrCommentTupleAsync(type).ConfigureAwait(false);
4235tuple_23 = await ParseCDataOrCommentTupleAsync(type).ConfigureAwait(false);
4250if (await ReadDataAsync().ConfigureAwait(false) == 0)
4419if (await ReadDataAsync().ConfigureAwait(false) == 0)
4444await EatWhitespacesAsync(null).ConfigureAwait(false);
4471_dtdInfo = await dtdParser.ParseInternalDtdAsync(new DtdParserProxy(this), true).ConfigureAwait(false);
4487var tuple_24 = await ParseQNameAsync().ConfigureAwait(false);
4494await EatWhitespacesAsync(null).ConfigureAwait(false);
4502if (await ReadDataAsync().ConfigureAwait(false) == 0)
4515if (await EatWhitespacesAsync(null).ConfigureAwait(false) == 0)
4524if (await EatWhitespacesAsync(null).ConfigureAwait(false) == 0)
4532await EatWhitespacesAsync(null).ConfigureAwait(false);
4539if (await ReadDataAsync().ConfigureAwait(false) == 0)
4552if (await EatWhitespacesAsync(null).ConfigureAwait(false) == 0)
4560await EatWhitespacesAsync(null).ConfigureAwait(false);
4574await EatWhitespacesAsync(null).ConfigureAwait(false);
4782if (await ReadDataAsync().ConfigureAwait(false) == 0)
4880if (await ReadDataAsync().ConfigureAwait(false) == 0)
4916if (await ReadDataAsync().ConfigureAwait(false) == 0)
4950if (await ReadDataAsync().ConfigureAwait(false) == 0)
4968var tuple_25 = await ParseQNameAsync(false, 0).ConfigureAwait(false);
4996var tuple_27 = await ReadDataInNameAsync(pos).ConfigureAwait(false);
5048var tuple_28 = await ReadDataInNameAsync(pos).ConfigureAwait(false);
5068bool newDataRead = (await ReadDataAsync().ConfigureAwait(false) != 0);
5079endPos = await ParseNameAsync().ConfigureAwait(false);
5110if (await OpenAndPushAsync(uri).ConfigureAwait(false))
5125if (await OpenAndPushAsync(uri).ConfigureAwait(false))
5166TextReader textReader = (TextReader)await _xmlResolver.GetEntityAsync(uri, null, typeof(TextReader)).ConfigureAwait(false);
5173await InitTextReaderInputAsync(uri.ToString(), uri, textReader).ConfigureAwait(false);
5180Stream stream = (Stream)await _xmlResolver.GetEntityAsync(uri, null, typeof(Stream)).ConfigureAwait(false);
5215await EatWhitespacesAsync(null).ConfigureAwait(false);
5217if (!await ParseXmlDeclarationAsync(true).ConfigureAwait(false))
5245if (_v1Compat && pos == _ps.charsUsed - 1 && _ps.chars[pos] == (char)0 && await ReadDataAsync().ConfigureAwait(false) == 0 && _ps.isStreamEof)
5260_dtdInfo = await dtdParser.ParseFreeFloatingDtdAsync(_fragmentParserContext.BaseURI, _fragmentParserContext.DocTypeName, _fragmentParserContext.PublicId, _fragmentParserContext.SystemId, _fragmentParserContext.InternalSubset, new DtdParserProxy(this)).ConfigureAwait(false);
5283if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
5302await _outerReader.ReadAsync().ConfigureAwait(false);
5309if (!await MoveToNextContentNodeAsync(false).ConfigureAwait(false))
5316await _outerReader.ReadAsync().ConfigureAwait(false);
5353} while (await _outerReader.ReadAsync().ConfigureAwait(false));
5441if (!await MoveToNextContentNodeAsync(true).ConfigureAwait(false))
5458int decoded = await ReadContentAsBinaryAsync(buffer, index, count).ConfigureAwait(false);
5476await _outerReader.ReadAsync().ConfigureAwait(false);
System\Xml\Core\XmlValidatingReaderImplAsync.cs (7)
31if (await _coreReader.ReadAsync().ConfigureAwait(false))
90int readCount = await _readBinaryHelper!.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
114int readCount = await _readBinaryHelper!.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
138int readCount = await _readBinaryHelper!.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
162int readCount = await _readBinaryHelper!.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
185IDtdInfo dtdInfo = await dtdParser.ParseFreeFloatingDtdAsync(_parserContext.BaseURI, _parserContext.DocTypeName, _parserContext.PublicId, _parserContext.SystemId, _parserContext.InternalSubset, proxy).ConfigureAwait(false);
196while (await _outerReader.ReadAsync().ConfigureAwait(false) && _coreReader.Depth > initialDepth) ;
System\Xml\Core\XsdValidatingReaderAsync.cs (25)
48object typedValue = await InternalReadContentAsObjectAsync().ConfigureAwait(false);
84var tuple_0 = await InternalReadContentAsObjectTupleAsync(false).ConfigureAwait(false);
129var tuple_1 = await InternalReadElementContentAsObjectAsync(true).ConfigureAwait(false);
143var content = await InternalReadElementContentAsObjectAsync().ConfigureAwait(false);
184var content = await InternalReadElementContentAsObjectTupleAsync(false).ConfigureAwait(false);
249if (await task.ConfigureAwait(false))
378await ReadAsync().ConfigureAwait(false);
401int readCount = await _readBinaryHelper.ReadContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
428int readCount = await _readBinaryHelper.ReadContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
455int readCount = await _readBinaryHelper.ReadElementContentAsBase64Async(buffer, index, count).ConfigureAwait(false);
482int readCount = await _readBinaryHelper.ReadElementContentAsBinHexAsync(buffer, index, count).ConfigureAwait(false);
537static async Task ValidateWhitespace(Task<string> t, XmlSchemaValidator validator) => validator.ValidateWhitespace(await t.ConfigureAwait(false));
539static async Task ValidateText(Task<string> t, XmlSchemaValidator validator) => validator.ValidateText(await t.ConfigureAwait(false));
654if (await _coreReader.ReadAsync().ConfigureAwait(false))
684var content = await InternalReadContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
734object? value = ReturnBoxedValue(await ReadTillEndElementAsync().ConfigureAwait(false), _xmlSchemaInfo.XmlType!, unwrapTypedValue);
751originalStringValue = await InternalReadContentAsStringAsync().ConfigureAwait(false);
766var content = await InternalReadElementContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
793await this.ReadAsync().ConfigureAwait(false);
799await this.ReadAsync().ConfigureAwait(false);
833var content = await InternalReadContentAsObjectTupleAsync(unwrapTypedValue).ConfigureAwait(false);
848await this.ReadAsync().ConfigureAwait(false);
857while (await _coreReader.ReadAsync().ConfigureAwait(false))
873_validator.ValidateText(await GetValueAsync().ConfigureAwait(false));
878_validator.ValidateWhitespace(await GetValueAsync().ConfigureAwait(false));
System\Xml\Schema\DtdParserAsync.cs (103)
78if (await GetTokenAsync(false).ConfigureAwait(false) != Token.QName)
85Token token = await GetTokenAsync(false).ConfigureAwait(false);
88var tuple_0 = await ParseExternalIdAsync(token, Token.DOCTYPE).ConfigureAwait(false);
92token = await GetTokenAsync(false).ConfigureAwait(false);
145if (!await _readerAdapter.PushExternalSubsetAsync(_systemId, _publicId).ConfigureAwait(false))
173Token token = await GetTokenAsync(false).ConfigureAwait(false);
239if (await GetTokenAsync(false).ConfigureAwait(false) != Token.GreaterThan)
290if (await GetTokenAsync(true).ConfigureAwait(false) != Token.QName)
310switch (await GetTokenAsync(false).ConfigureAwait(false))
398Token token = await GetTokenAsync(true).ConfigureAwait(false);
447if (await GetTokenAsync(true).ConfigureAwait(false) != Token.LeftParen)
453if (await GetTokenAsync(false).ConfigureAwait(false) != Token.Name)
470switch (await GetTokenAsync(false).ConfigureAwait(false))
473if (await GetTokenAsync(false).ConfigureAwait(false) != Token.Name)
491if (await GetTokenAsync(false).ConfigureAwait(false) != Token.Nmtoken)
497switch (await GetTokenAsync(false).ConfigureAwait(false))
500if (await GetTokenAsync(false).ConfigureAwait(false) != Token.Nmtoken)
527switch (await GetTokenAsync(true).ConfigureAwait(false))
537if (await GetTokenAsync(true).ConfigureAwait(false) != Token.Literal)
575if (await GetTokenAsync(true).ConfigureAwait(false) != Token.QName)
606switch (await GetTokenAsync(true).ConfigureAwait(false))
616switch (await GetTokenAsync(false).ConfigureAwait(false))
649if (await GetTokenAsync(false).ConfigureAwait(false) != Token.GreaterThan)
668switch (await GetTokenAsync(false).ConfigureAwait(false))
697switch (await GetTokenAsync(false).ConfigureAwait(false))
751switch (await GetTokenAsync(false).ConfigureAwait(false))
775switch (await GetTokenAsync(false).ConfigureAwait(false))
783if (await GetTokenAsync(false).ConfigureAwait(false) == Token.Star && hasNames)
810if (await GetTokenAsync(false).ConfigureAwait(false) != Token.QName)
844switch (await GetTokenAsync(true).ConfigureAwait(false))
848if (await GetTokenAsync(true).ConfigureAwait(false) != Token.Name)
876Token token = await GetTokenAsync(true).ConfigureAwait(false);
884var tuple_1 = await ParseExternalIdAsync(token, Token.EntityDecl).ConfigureAwait(false);
892if (await GetTokenAsync(false).ConfigureAwait(false) == Token.NData)
903if (await GetTokenAsync(true).ConfigureAwait(false) != Token.Name)
925if (await GetTokenAsync(false).ConfigureAwait(false) == Token.GreaterThan)
938if (await GetTokenAsync(true).ConfigureAwait(false) != Token.Name)
962Token token = await GetTokenAsync(true).ConfigureAwait(false);
967var tuple_2 = await ParseExternalIdAsync(token, Token.NOTATION).ConfigureAwait(false);
982if (await GetTokenAsync(false).ConfigureAwait(false) != Token.GreaterThan)
1036switch (await GetTokenAsync(false).ConfigureAwait(false))
1039if (await GetTokenAsync(false).ConfigureAwait(false) != Token.LeftBracket)
1064if (await GetTokenAsync(false).ConfigureAwait(false) != Token.LeftBracket)
1073if (await GetTokenAsync(false).ConfigureAwait(false) != Token.CondSectionEnd)
1097if (await GetTokenAsync(true).ConfigureAwait(false) != Token.Literal)
1134if (await GetTokenAsync(false).ConfigureAwait(false) == Token.Literal)
1151if (await GetTokenAsync(false).ConfigureAwait(false) == Token.Literal)
1233await HandleEntityReferenceAsync(true, false, false).ConfigureAwait(false);
1247case ScanningFunction.Name: return await ScanNameExpectedAsync().ConfigureAwait(false);
1248case ScanningFunction.QName: return await ScanQNameExpectedAsync().ConfigureAwait(false);
1249case ScanningFunction.Nmtoken: return await ScanNmtokenExpectedAsync().ConfigureAwait(false);
1250case ScanningFunction.SubsetContent: return await ScanSubsetContentAsync().ConfigureAwait(false);
1251case ScanningFunction.Doctype1: return await ScanDoctype1Async().ConfigureAwait(false);
1253case ScanningFunction.Element1: return await ScanElement1Async().ConfigureAwait(false);
1254case ScanningFunction.Element2: return await ScanElement2Async().ConfigureAwait(false);
1255case ScanningFunction.Element3: return await ScanElement3Async().ConfigureAwait(false);
1260case ScanningFunction.Attlist1: return await ScanAttlist1Async().ConfigureAwait(false);
1261case ScanningFunction.Attlist2: return await ScanAttlist2Async().ConfigureAwait(false);
1265case ScanningFunction.Attlist6: return await ScanAttlist6Async().ConfigureAwait(false);
1267case ScanningFunction.Notation1: return await ScanNotation1Async().ConfigureAwait(false);
1268case ScanningFunction.SystemId: return await ScanSystemIdAsync().ConfigureAwait(false);
1269case ScanningFunction.PublicId1: return await ScanPublicId1Async().ConfigureAwait(false);
1270case ScanningFunction.PublicId2: return await ScanPublicId2Async().ConfigureAwait(false);
1271case ScanningFunction.Entity1: return await ScanEntity1Async().ConfigureAwait(false);
1272case ScanningFunction.Entity2: return await ScanEntity2Async().ConfigureAwait(false);
1273case ScanningFunction.Entity3: return await ScanEntity3Async().ConfigureAwait(false);
1274case ScanningFunction.CondSection1: return await ScanCondSection1Async().ConfigureAwait(false);
1276case ScanningFunction.CondSection3: return await ScanCondSection3Async().ConfigureAwait(false);
1288if (_readerAdapter.IsEof || await ReadDataAsync().ConfigureAwait(false) == 0)
1464if (await ReadDataAsync().ConfigureAwait(false) == 0)
1497if (!await EatPublicKeywordAsync().ConfigureAwait(false))
1505if (!await EatSystemKeywordAsync().ConfigureAwait(false))
1566if (await ReadDataAsync().ConfigureAwait(false) == 0)
1579if (await ReadDataAsync().ConfigureAwait(false) == 0)
1763if (await ReadDataAsync().ConfigureAwait(false) == 0)
1778await ScanLiteralAsync(LiteralType.AttributeValue).ConfigureAwait(false);
1830if (await ReadDataAsync().ConfigureAwait(false) == 0)
1953await HandleEntityReferenceAsync(true, true, literalType == LiteralType.AttributeValue).ConfigureAwait(false);
1971int endPos = await _readerAdapter.ParseNumericCharRefAsync(SaveInternalSubsetValue ? _internalSubsetValueSb : null).ConfigureAwait(false);
1985int endPos = await _readerAdapter.ParseNamedCharRefAsync(true, SaveInternalSubsetValue ? _internalSubsetValueSb : null).ConfigureAwait(false);
1998await HandleEntityReferenceAsync(false, true, true).ConfigureAwait(false);
2005int endPos = await _readerAdapter.ParseNamedCharRefAsync(false, null).ConfigureAwait(false);
2058if (_readerAdapter.IsEof || await ReadDataAsync().ConfigureAwait(false) == 0)
2074if (!await EatPublicKeywordAsync().ConfigureAwait(false))
2082if (!await EatSystemKeywordAsync().ConfigureAwait(false))
2102await ScanLiteralAsync(LiteralType.SystemOrPublicID).ConfigureAwait(false);
2130if (!await EatPublicKeywordAsync().ConfigureAwait(false))
2138if (!await EatSystemKeywordAsync().ConfigureAwait(false))
2148await ScanLiteralAsync(LiteralType.EntityReplText).ConfigureAwait(false);
2163if (await ReadDataAsync().ConfigureAwait(false) == 0)
2189await ScanLiteralAsync(LiteralType.SystemOrPublicID).ConfigureAwait(false);
2203await ScanLiteralAsync(LiteralType.SystemOrPublicID).ConfigureAwait(false);
2256if (await ReadDataAsync().ConfigureAwait(false) == 0)
2368if (_readerAdapter.IsEof || await ReadDataAsync().ConfigureAwait(false) == 0)
2405if (await ReadDataInNameAsync().ConfigureAwait(false))
2451if (await ReadDataInNameAsync().ConfigureAwait(false))
2470bool newDataRead = (await ReadDataAsync().ConfigureAwait(false) != 0);
2505if (await ReadDataAsync().ConfigureAwait(false) == 0)
2525if (await ReadDataAsync().ConfigureAwait(false) == 0)
2544if (await ReadDataAsync().ConfigureAwait(false) == 0)
2564int charsRead = await _readerAdapter.ReadDataAsync().ConfigureAwait(false);
2603var tuple_3 = await _readerAdapter.PushEntityAsync(entity).ConfigureAwait(false);
2619var tuple_4 = await _readerAdapter.PushEntityAsync(entity).ConfigureAwait(false);
System.Private.Xml.Linq (26)
System\Xml\Linq\XContainer.cs (15)
861while (await cr.ReadContentFromAsync(this, r).ConfigureAwait(false) && await r.ReadAsync().ConfigureAwait(false));
878while (await cr.ReadContentFromContainerAsync(this, r).ConfigureAwait(false) && await r.ReadAsync().ConfigureAwait(false));
967await r.GetValueAsync().ConfigureAwait(false)));
985_currentContainer.AddStringSkipNotify(await r.GetValueAsync().ConfigureAwait(false));
988_currentContainer.AddNodeSkipNotify(new XCData(await r.GetValueAsync().ConfigureAwait(false)));
991_currentContainer.AddNodeSkipNotify(new XComment(await r.GetValueAsync().ConfigureAwait(false)));
994_currentContainer.AddNodeSkipNotify(new XProcessingInstruction(r.Name, await r.GetValueAsync().ConfigureAwait(false)));
997_currentContainer.AddNodeSkipNotify(new XDocumentType(r.LocalName, r.GetAttribute("PUBLIC"), r.GetAttribute("SYSTEM"), await r.GetValueAsync().ConfigureAwait(false)));
1149await r.GetValueAsync().ConfigureAwait(false));
1194newNode = new XText(await r.GetValueAsync().ConfigureAwait(false));
1198_currentContainer.AddStringSkipNotify(await r.GetValueAsync().ConfigureAwait(false));
1202newNode = new XCData(await r.GetValueAsync().ConfigureAwait(false));
1205newNode = new XComment(await r.GetValueAsync().ConfigureAwait(false));
1208newNode = new XProcessingInstruction(r.Name, await r.GetValueAsync().ConfigureAwait(false));
1211newNode = new XDocumentType(r.LocalName, r.GetAttribute("PUBLIC"), r.GetAttribute("SYSTEM"), await r.GetValueAsync().ConfigureAwait(false));
System.Security.Cryptography.Cose (2)
System.ServiceModel.Federation (1)
System.ServiceModel.NetFramingBase (1)
System.Text.Json (1)
System.Text.RegularExpressions.Generator (5)
System.Threading.RateLimiting (1)
System.Threading.Tasks.Dataflow (2)
System.Windows.Forms (4)
System.Windows.Forms.Analyzers.CodeFixes.CSharp (2)
System.Windows.Forms.Analyzers.CodeFixes.VisualBasic (2)
System.Windows.Forms.Analyzers.CSharp.Tests (1)
System.Windows.Forms.Analyzers.Tests (5)
Test.Utilities (20)
Text.Analyzers (74)
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\Editing\ImportAdderService.cs (3)
58return await AddImportDirectivesFromSymbolAnnotationsAsync(document, annotatedNodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
65return await AddImportDirectivesFromSyntaxesAsync(document, nodes, addImportsService, generator, options, cancellationToken).ConfigureAwait(false);
243cancellationToken).ConfigureAwait(false);
src\Workspaces\SharedUtilitiesAndExtensions\Workspace\Core\LanguageServices\MoveDeclarationNearReference\AbstractMoveDeclarationNearReferenceService.cs (8)
40var state = await ComputeStateAsync(document, node, cancellationToken).ConfigureAwait(false);
54var state = await State.GenerateAsync((TService)this, document, statement, cancellationToken).ConfigureAwait(false);
62!await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false))
80var state = await ComputeStateAsync(document, localDeclarationStatement, cancellationToken).ConfigureAwait(false);
84var root = await document.GetSyntaxRootAsync(cancellationToken).ConfigureAwait(false);
92var canMergeDeclarationAndAssignment = await CanMergeDeclarationAndAssignmentAsync(document, state, cancellationToken).ConfigureAwait(false);
124state.DeclarationStatement, document, cancellationToken: cancellationToken).ConfigureAwait(false);
226document, localSymbol, state.DeclarationStatement, right, cancellationToken).ConfigureAwait(false);
vbc (7)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
VBCSCompiler (22)
src\Compilers\Shared\BuildServerConnection.cs (6)
117cancellationToken).ConfigureAwait(false);
184using var pipe = await tryConnectToServerAsync(pipeName, timeoutOverride, logger, tryCreateServerFunc, cancellationToken).ConfigureAwait(false);
191return await tryRunRequestAsync(pipe, buildRequest, logger, cancellationToken).ConfigureAwait(false);
299await Task.WhenAny(responseTask, monitorTask).ConfigureAwait(false);
309response = await responseTask.ConfigureAwait(false);
350await pipeStream.ReadAsync(buffer, 0, 0, cancellationToken).ConfigureAwait(false);
VBCSCompiler.UnitTests (1)