core/alet works in unexpected way
Open
bug
- Dominant language
- Clojure
- Stars
- 970
- Forks
- 68
- PR merge metrics
- No merged PRs in 30d
Description
Hi!
Seems like when one of `alet` args in not wrapped into monad it returns the value of the last of that arg.
Better show than explain:
```
err.core=> (alet [a (ei/right 1) b (inc a)] 42)
2
err.core=> (alet [a (ei/right 1) b (ei/right (inc a))] 42)
#
err.core=> (alet [a (ei/right 1) b (inc a) c (+ b 4)] 42)
IllegalArgumentException No context is set and it can not be automatically resolved from provided value cats.context/throw-illegal-argument (context.cljc:32)
err.core=> (alet [a (ei/right 1) b (inc a) c (+ a 4)] 42)
2
```
I think it should raise exception in all that cases.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.