dotnet / roslyn-analyzers

MIT License
1.6k stars 466 forks source link

[9.0] Source-build issue in stage 2 build #7429

Closed NikolaMilosavljevic closed 1 month ago

NikolaMilosavljevic commented 1 month ago

Originally created in source-build repo: https://github.com/dotnet/source-build/issues/4642

Stage 2 build is failing in roslyn-analyzers with the following errors:

    /vmr/src/roslyn-analyzers/src/Utilities/FlowAnalysis/FlowAnalysis/Framework/DataFlow/AnalysisEntity.cs(189,35): warning CS9258: In language version preview, the 'field' keyword binds to a synthesized backing field for the property. To avoid generating a synthesized backing field, and to refer to the existing member, use 'this.field' or '@field' instead. [/vmr/src/roslyn-analyzers/src/Microsoft.CodeAnalysis.AnalyzerUtilities/Microsoft.CodeAnalysis.AnalyzerUtilities.csproj]
    /vmr/src/roslyn-analyzers/src/Utilities/FlowAnalysis/FlowAnalysis/Framework/DataFlow/AnalysisEntity.cs(189,35): warning CS9258: In language version preview, the 'field' keyword binds to a synthesized backing field for the property. To avoid generating a synthesized backing field, and to refer to the existing member, use 'this.field' or '@field' instead. [/vmr/src/roslyn-analyzers/src/NetAnalyzers/Core/Microsoft.CodeAnalysis.NetAnalyzers.csproj]
    /vmr/src/roslyn-analyzers/src/Utilities/FlowAnalysis/FlowAnalysis/Framework/DataFlow/AnalysisEntity.cs(189,41): error CS0428: Cannot convert method group 'HasConstantValue' to non-delegate type 'bool'. Did you intend to invoke the method? [/vmr/src/roslyn-analyzers/src/Microsoft.CodeAnalysis.AnalyzerUtilities/Microsoft.CodeAnalysis.AnalyzerUtilities.csproj]
    /vmr/src/roslyn-analyzers/src/Utilities/FlowAnalysis/FlowAnalysis/Framework/DataFlow/AnalysisEntity.cs(189,41): error CS0428: Cannot convert method group 'HasConstantValue' to non-delegate type 'bool'. Did you intend to invoke the method? [/vmr/src/roslyn-analyzers/src/NetAnalyzers/Core/Microsoft.CodeAnalysis.NetAnalyzers.csproj]

Test build (internal link): https://dev.azure.com/dnceng/internal/_build/results?buildId=2550485&view=logs&j=3121c41d-6088-53a5-4ef6-9a86f3460fe9&t=334539f4-dcef-5cad-a240-02997b3146e7

This can be reproduced in vstest repo builds by updating SDK to the latest 9.0 build.

cc @mavasani