You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
May<T>.Match<T, TOut>(Func<T, TOut> valueProjection, TOut alternativeValue)
The first variant must not be called with alternativeFunc being null. The second may be called with null, but if written as plain code, using null here the compiler usually resolves it to the first variant, and by that failing at runtime.
the May type from the Strilang.Value package has two overloads for the Match() function.
May<T>.Match<T, TOut>(Func<T, TOut> valueProjection, Func<TOut> alternativeFunc)
May<T>.Match<T, TOut>(Func<T, TOut> valueProjection, TOut alternativeValue)
The first variant must not be called with
alternativeFunc
beingnull
. The second may be called with null, but if written as plain code, usingnull
here the compiler usually resolves it to the first variant, and by that failing at runtime.Project on GitHub: https://github.com/Strilanc
Package in NuGet: https://www.nuget.org/packages/Strilanc.Value.May
The text was updated successfully, but these errors were encountered: