dotnet / dotnet/sdk

Compilation of this example with VS in .net8 hanging

Open
#51,937 4 comments 2 reactions 2 assignees Claimed by @krwq View on GitHub
Area-Microsoft.CodeAnalysis.NetAnalyzers Priority:0
Dominant language
C#
Stars
3.2k
Forks
1.3k
PR merge metrics
PR metrics pending

Description

.NET 8.0
VisualStudio.17.Release/17.14.13+36414.22.-august.2025-
Microsoft .NET Framework
Version 4.8.09037
Installed Version: Professional
C# Tools 4.14.0-3.25412.6+c167adef821b9ba2f1c44c227a5e79ca11876461

My test project compiles successfully in net6, but in net8 it causes the Roslyn analyzer and compilation to hang.

**To reproduce**:

1. Open solution from attached source-code: [Net8CodeAnalysisHangingExample.zip](https://github.com/user-attachments/files/23771726/Net8CodeAnalysisHangingExample.zip)
2. Start solution building

**Expected Behavior**: Successful solution build.

**Actual Behavior**: Compilation hanging.

Image

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.