Skip to content

Commit

Permalink
Renames
Browse files Browse the repository at this point in the history
  • Loading branch information
CyrusNajmabadi committed May 24, 2024
1 parent 5f6d7f2 commit cb26888
Show file tree
Hide file tree
Showing 5 changed files with 7 additions and 7 deletions.
6 changes: 3 additions & 3 deletions src/Workspaces/Core/Portable/Workspace/Solution/Solution.cs
Original file line number Diff line number Diff line change
Expand Up @@ -1579,9 +1579,9 @@ internal Document WithFrozenSourceGeneratedDocument(
internal Solution WithFrozenSourceGeneratedDocuments(ImmutableArray<(SourceGeneratedDocumentIdentity documentIdentity, DateTime generationDateTime, SourceText text)> documents)
=> WithCompilationState(_compilationState.WithFrozenSourceGeneratedDocuments(documents));

/// <inheritdoc cref="SolutionCompilationState.WithSourceGeneratorExecutionVersions"/>
internal Solution WithSourceGeneratorExecutionVersions(SourceGeneratorExecutionVersionMap sourceGeneratorExecutionVersionMap, CancellationToken cancellationToken)
=> WithCompilationState(_compilationState.WithSourceGeneratorExecutionVersions(sourceGeneratorExecutionVersionMap, cancellationToken));
/// <inheritdoc cref="SolutionCompilationState.UpdateSpecificSourceGeneratorExecutionVersions"/>
internal Solution UpdateSpecificSourceGeneratorExecutionVersions(SourceGeneratorExecutionVersionMap sourceGeneratorExecutionVersionMap, CancellationToken cancellationToken)
=> WithCompilationState(_compilationState.UpdateSpecificSourceGeneratorExecutionVersions(sourceGeneratorExecutionVersionMap, cancellationToken));

/// <summary>
/// Undoes the operation of <see cref="WithFrozenSourceGeneratedDocument"/>; any frozen source generated document is allowed
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1253,7 +1253,7 @@ public SolutionCompilationState WithOptions(SolutionOptionSet options)
/// name="sourceGeneratorExecutionVersions"/> must refer to projects in this solution. Projects not mentioned in
/// <paramref name="sourceGeneratorExecutionVersions"/> will not be touched (and they will stay in the map).
/// </summary>
public SolutionCompilationState WithSourceGeneratorExecutionVersions(
public SolutionCompilationState UpdateSpecificSourceGeneratorExecutionVersions(
SourceGeneratorExecutionVersionMap sourceGeneratorExecutionVersions, CancellationToken cancellationToken)
{
var versionMapBuilder = _sourceGeneratorExecutionVersionMap.Map.ToBuilder();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ await this.SetCurrentSolutionAsync(
oldSolution =>
{
var updates = GetUpdatedSourceGeneratorVersions(oldSolution, projectIds);
return oldSolution.WithSourceGeneratorExecutionVersions(updates, cancellationToken);
return oldSolution.UpdateSpecificSourceGeneratorExecutionVersions(updates, cancellationToken);
},
static (_, _) => (WorkspaceChangeKind.SolutionChanged, projectId: null, documentId: null),
onBeforeUpdate: null,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ public async Task<Solution> CreateSolutionAsync(Checksum newSolutionChecksum, Ca
}
#endif

solution = solution.WithSourceGeneratorExecutionVersions(newVersions, cancellationToken);
solution = solution.UpdateSpecificSourceGeneratorExecutionVersions(newVersions, cancellationToken);
}

#if DEBUG
Expand Down
2 changes: 1 addition & 1 deletion src/Workspaces/Remote/ServiceHub/Host/RemoteWorkspace.cs
Original file line number Diff line number Diff line change
Expand Up @@ -256,7 +256,7 @@ private async Task<Solution> ComputeDisconnectedSolutionAsync(
var newVersions = await assetProvider.GetAssetAsync<SourceGeneratorExecutionVersionMap>(
AssetPathKind.SolutionSourceGeneratorExecutionVersionMap, newSolutionCompilationChecksums.SourceGeneratorExecutionVersionMap, cancellationToken).ConfigureAwait(false);

solution = solution.WithSourceGeneratorExecutionVersions(newVersions, cancellationToken);
solution = solution.UpdateSpecificSourceGeneratorExecutionVersions(newVersions, cancellationToken);
}

return solution;
Expand Down

0 comments on commit cb26888

Please sign in to comment.