Show, don't tell thread about covariance and contravariance in C#.
#csharp #dotnet #dotnetcore
In case that you wonder why variance is not automatic...
Can we somehow avoid covariant type parameter? Yes.
Does all this make sense?
For more details get one copy of C# 8.0 in a Nutshell. I highly recommend this book.
Tip: mention @twtextapp on a Twitter thread with the keyword “unroll” to get a link to it.