New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Pattern Matching [Maybe] Issue with Aff #1243
Comments
I'd expect it to be in a Fail state, yes. Could you step into the functions to see how it's happened? And what the actual state of the Fin is? (I'm assuming Bottom). |
Sorry, just read your comment fully. It looks like you're right that anything object would match first, so yes, that's a bug. If you want to submit a fix, I'm due to do a new release soon. |
How large of a changeset would you like this to be? For example, change just that one method, or look over that file, or include other files that have the generic before the |
I will accept any amount of help! If you're willing to find all of the similar issues and fix (search for '.Case'), that's awesome. If you fix this one instance, that's awesome too! |
I ran into a problem while unit testing my application, and wanted to get your opinion to determine if this is a bug or it behaves as expected. Really, I got lazy with unit testing on a generic method so I used
object
withAff<T>.MapFail
, which resulted in theError
object succeeding because the pattern matching has the generic type matched before the Error object.language-ext/LanguageExt.Core/Effects/Eff/Extensions/Eff.Extensions.cs
Lines 43 to 48 in d42c12a
Here is a simple replication:
Unit Test
Would you expect
IsFail
to be true or false?The text was updated successfully, but these errors were encountered: