dotnet/roslyn

Constant folding isn't done when interpolated string contains at least one variable

Open

#65,636 建立於 2022年11月28日

在 GitHub 查看
 (2 留言) (0 反應) (0 負責人)C# (4,257 fork)batch import
Area-Compilershelp wanted

倉庫指標

Star
 (20,414 star)
PR 合併指標
 (平均合併 6天 17小時) (30 天內合併 256 個 PR)

描述

Version Used: Not sure, whatever sharplab/Default is at.

Steps to Reproduce:

Explained in this sharplab snippet

Expected Behavior:

The left side of the string is constant folded in the optimized version.

Actual Behavior:

The left side of the string is not constant folded in the optimized version, generating InterpolatedStringHandler operations for what are constant strings

貢獻者指南