dotnet/roslyn
View on GitHub'Convert to raw string without leading whitespace' erroneously strips trailing whitespace
Open
#62,376 opened on Jul 5, 2022
Area-IDEBughelp wanted
Repository metrics
- Stars
- (20,414 stars)
- PR merge metrics
- (Avg merge 6d 17h) (256 merged PRs in 30d)
Description
Version Used: 17.3.0-p2.0
This is not the semantics change described by the light bulb fix.
var whereClause = "Age >= 18";
var x = @"
select FirstName, LastName
from dbo.People
where " + whereClause;
💡 "Convert to raw string without leading whitespace (may change semantics)":
var whereClause = "Age >= 18";
var x = """
select FirstName, LastName
from dbo.People
where
""" + whereClause;
The resulting string contains whereAge >= 18 instead of where Age >= 18.