mirror of
https://github.com/idris-lang/Idris2.git
synced 2024-12-17 00:10:31 +03:00
8fd58b3bdd
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) | ^^^^^^^^^ ```
4 lines
77 B
Plaintext
4 lines
77 B
Plaintext
1/1: Building TestException (TestException.idr)
|
|
TestException>
|
|
Bye for now!
|