@@ -566,7 +566,7 @@ private static ProjectAnalysisSummary GetProjectAnalysisSummary(ImmutableArray<D
566
566
// rude edit detection wasn't completed due to errors that prevent us from analyzing the document:
567
567
if ( analysis . HasChangesAndSyntaxErrors )
568
568
{
569
- return ProjectAnalysisSummary . CompilationErrors ;
569
+ return ProjectAnalysisSummary . SyntaxErrors ;
570
570
}
571
571
572
572
// rude edits detected:
@@ -807,14 +807,14 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
807
807
{
808
808
if ( newProject . FilePath == null )
809
809
{
810
- log . Write ( "Skipping project '{0}' without a file path" , newProject . Id ) ;
810
+ log . Write ( "Skipping project '{0}' without a file path" , newProject . Name ) ;
811
811
continue ;
812
812
}
813
813
814
814
var oldProject = oldSolution . GetProject ( newProject . Id ) ;
815
815
if ( oldProject == null )
816
816
{
817
- log . Write ( "EnC state of ' {0}' queried: project not loaded" , newProject . Id ) ;
817
+ log . Write ( "EnC state of {0} '{1}' queried: project not loaded" , newProject . Name , newProject . FilePath ) ;
818
818
819
819
// TODO (https://github.com/dotnet/roslyn/issues/1204):
820
820
//
@@ -836,7 +836,7 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
836
836
continue ;
837
837
}
838
838
839
- log . Write ( "Found {0} potentially changed document(s) in project ' {1}' " , changedOrAddedDocuments . Count , newProject . Id ) ;
839
+ log . Write ( "Found {0} potentially changed document(s) in project {1} '{2}' " , changedOrAddedDocuments . Count , newProject . Name , newProject . FilePath ) ;
840
840
841
841
var ( mvid , mvidReadError ) = await DebuggingSession . GetProjectModuleIdAsync ( newProject , cancellationToken ) . ConfigureAwait ( false ) ;
842
842
if ( mvidReadError != null )
@@ -853,7 +853,7 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
853
853
854
854
if ( mvid == Guid . Empty )
855
855
{
856
- log . Write ( "Emitting update of ' {0}' : project not built" , newProject . Id ) ;
856
+ log . Write ( "Emitting update of {0} '{1}' : project not built" , newProject . Name , newProject . FilePath ) ;
857
857
continue ;
858
858
}
859
859
@@ -884,7 +884,14 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
884
884
885
885
foreach ( var changedDocumentAnalysis in changedDocumentAnalyses )
886
886
{
887
- if ( changedDocumentAnalysis . HasChanges )
887
+ if ( changedDocumentAnalysis . SyntaxError != null )
888
+ {
889
+ // only remember the first syntax error we encounter:
890
+ syntaxError ??= changedDocumentAnalysis . SyntaxError ;
891
+
892
+ log . Write ( "Changed document '{0}' has syntax error: {1}" , changedDocumentAnalysis . FilePath , changedDocumentAnalysis . SyntaxError ) ;
893
+ }
894
+ else if ( changedDocumentAnalysis . HasChanges )
888
895
{
889
896
log . Write ( "Document changed, added, or deleted: '{0}'" , changedDocumentAnalysis . FilePath ) ;
890
897
}
@@ -893,7 +900,7 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
893
900
}
894
901
895
902
var projectSummary = GetProjectAnalysisSummary ( changedDocumentAnalyses ) ;
896
- log . Write ( "Project summary for ' {0}' : {1 }" , newProject . Id , projectSummary ) ;
903
+ log . Write ( "Project summary for {0} '{1}' : {2 }" , newProject . Name , newProject . FilePath , projectSummary ) ;
897
904
898
905
if ( projectSummary == ProjectAnalysisSummary . NoChanges )
899
906
{
@@ -912,13 +919,7 @@ public async ValueTask<SolutionUpdate> EmitSolutionUpdateAsync(Solution solution
912
919
isBlocked = true ;
913
920
}
914
921
915
- if ( projectSummary == ProjectAnalysisSummary . CompilationErrors )
916
- {
917
- // only remember the first syntax error we encounter:
918
- syntaxError ??= changedDocumentAnalyses . FirstOrDefault ( a => a . SyntaxError != null ) ? . SyntaxError ;
919
- isBlocked = true ;
920
- }
921
- else if ( projectSummary == ProjectAnalysisSummary . RudeEdits )
922
+ if ( projectSummary is ProjectAnalysisSummary . SyntaxErrors or ProjectAnalysisSummary . RudeEdits )
922
923
{
923
924
isBlocked = true ;
924
925
}
@@ -977,7 +978,7 @@ async ValueTask LogDocumentChangesAsync(int? generation, CancellationToken cance
977
978
}
978
979
}
979
980
980
- log . Write ( "Emitting update of '{0}'" , newProject . Id ) ;
981
+ log . Write ( "Emitting update of '{0}' {1} " , newProject . Name , newProject . FilePath ) ;
981
982
982
983
var newCompilation = await newProject . GetCompilationAsync ( cancellationToken ) . ConfigureAwait ( false ) ;
983
984
Contract . ThrowIfNull ( newCompilation ) ;
0 commit comments