dotnet/roslyn

[C#] Nested curly brace is not auto completed in interpolated string

Open

#72,116 opened on Feb 15, 2024

View on GitHub
 (1 comment) (0 reactions) (0 assignees)C# (4,257 forks)batch import
Area-IDEhelp wanted

Repository metrics

Stars
 (20,414 stars)
PR merge metrics
 (Avg merge 6d 17h) (256 merged PRs in 30d)

Description

Ported from: https://devdiv.visualstudio.com/DevDiv/_workitems/edit/1956301

Open C# console app Type the following characters

var x = $"{{

Expected (| indicating the caret): string x = $"{{|}}" Actual: string x = $"{{|}"

--

Note: When fixing this, fix https://github.com/dotnet/roslyn/issues/61541 as well (the raw string literal case).

Contributor guide