Skip to content

Commit

Permalink
Replace use of 'record' type.
Browse files Browse the repository at this point in the history
  • Loading branch information
manfred-brands committed Mar 12, 2024
1 parent 0aacb17 commit 1703848
Showing 1 changed file with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1017,7 +1017,15 @@ public void Test(string ?possibleNullString)
return str.Inner; // warning: possible null reference return
}
private record HasString(string? Inner);
private sealed class HasString
{
public HasString(string? inner)
{
Inner = inner;
}
public string? Inner { get; }
}
");

RoslynAssert.Suppressed(suppressor,
Expand Down

0 comments on commit 1703848

Please sign in to comment.