Closed mlegenhausen closed 1 year ago
No, because all values are always wrapped in a closure, but we could align the implementations so we don't have two strategies. WDYT?
Just noticed this should also fix matchX
: https://github.com/unsplash/sum-types/pull/57/files#diff-a2a171449d862fe29692ce031981047d7ab755ae7f84c707aef80701b3ea0c80L281
Would be good to add a test case for that as well.
We could align the implementations so we don't have two strategies. WDYT?
There's certainly more duplication than I'd like.
Ah I misread you meant matchX
not match
. Yes it had the same problem because it is an alias.
@samhh could you publish a bugfix release? Thanks.
Currently it is not possible to use
undefined
as return value formatchXW
. This PR solves this use by using thein
operator to check for the existence of atag
instead of comparing withundefined
.