This website requires JavaScript.
Explore
Help
Sign In
idris-lang
/
Idris2
Watch
1
Star
1
Fork
0
You've already forked Idris2
mirror of
https://github.com/idris-lang/Idris2.git
synced
2024-12-21 02:31:50 +03:00
Code
Issues
Projects
Releases
Wiki
Activity
ac266b73f8
Idris2
/
tests
/
base
/
control_app001
/
run
4 lines
46 B
Plaintext
Raw
Normal View
History
Unescape
Escape
Add testing utilities script
2023-08-29 13:47:42 +03:00
. ../../testutils.sh
More reliable exception handling in Control.App Convert `App.Control.Exception` interface to an alias to `HasErr`. Probably `Exception` interface need to be deprecated or removed. Note similar problem exists with `PrimIO` calling `PrimIO, Exception`, also need to be fixed. Fix this scenario: ``` throwBoth : Has [Exception String, Exception Int] es => App es () throwOne : Has [Exception Int] es => App es Int throwOne {es} = handle {err = String} {e = es} throwBoth (\r => pure 1) (\e => pure 3) ``` With this commit it works, before this commit it failed with: ``` Error: While processing right hand side of throwOne. Can't find an implementation for Exception Int (String :: es). TestException.idr:8:48--8:57 | 8 | throwOne {es} = handle {err = String} {e = es} throwBoth (\r => pure 1) (\e => pure 3) | ^^^^^^^^^ ```
2021-02-02 22:42:03 +03:00
Remove trivial testing input files
2023-08-29 19:02:01 +03:00
check TestException.idr
Reference in New Issue
Copy Permalink