Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Simpler implementation of applicative effect for errors catching (#161)
* Simpler implementation of applicative effect for errors catching * Simple implementation of the generalized `catchWrongs` was added This implementation does not handle multiple at once in case of S = List when several wrongs came from several `flatMap`'s, but catch all correctly when several wrongs came from `Traverse`. * Method for catching the first Wrong was implemented thru the general one. * Old catch implementation was aliased to `catchFirstWrong` and deprecated * Errors were made to be catched not as eager as they were before. This allows us to implement catch-last and catch-all behaviours correctly. * Syntax methods were added for newer functions, deprecation was corrected * Catch-all method was added taking `Nel[E] => Eff` handler. * Catch-last was added. * Deprecated method was replaced with its substitute in the spec. * Bunch of tests for multi-errors catch was added. * Continuation was made to be called in the applicative case of catch * Try to fix compatibility with scala 2.11. * Simplification of applicative catch, getting rid of coercion. * Getting rid of another coertion (in slightly unrelated place) * Versions in were updated in deprecations * Getting rid of unnecessary repetition. * One test's name was made to be cleaner * Smashing of all strings in the `catchAllWrongs` test has been moved out * Tests of catching using `Applicative` instance of `Eff` were added. * Multi-catching tests were reorganized, common parts were moved out. * Small typo was fixed. * One more small tests reorganization was done. * Errors in applicative block were renumbered to be the same with monadic * Multicatch tests were made to be two-level. * One typo was fixed.
- Loading branch information
1 parent
6360517
commit e45f93a
Showing
3 changed files
with
143 additions
and
25 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters