Skip to content

Commit 3cea483

Browse files
Add test for expression-bodied lambda list with comma
Co-authored-by: CyrusNajmabadi <4564579+CyrusNajmabadi@users.noreply.github.com>
1 parent a170664 commit 3cea483

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

src/Workspaces/CSharpTest/Formatting/FormattingTests.cs

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -442,6 +442,22 @@ void M()
442442
}
443443
""");
444444

445+
[Fact, WorkItem("https://github.com/dotnet/roslyn/issues/10526")]
446+
public Task ExpressionLambdaListWithComma()
447+
=> AssertNoFormattingChangesAsync("""
448+
using System;
449+
450+
class Test
451+
{
452+
void M()
453+
{
454+
int x = 1, y = 2;
455+
Func<int> a = () => x,
456+
b = () => y;
457+
}
458+
}
459+
""");
460+
445461
[Fact]
446462
public Task Scen1()
447463
=> AssertFormatAsync("""

0 commit comments

Comments
 (0)