ref: 0e987e21af03dccfe1b37141ca024f657238dfd2
parent: 7cb2053ab0228919b08a6c3674de5f474b431cc2
parent: 053f240f3955c801accece839039813f0fea64c0
author: Ori Bernstein <[email protected]>
date: Wed Aug 14 17:26:36 EDT 2013
Merge branch 'master' of git+ssh://git.eigenstate.org/git/ori/mc
--- a/libstd/error.myr
+++ b/libstd/error.myr
@@ -1,19 +1,9 @@
-pkg std =
- type error(@a, @b)
+use "die.use"
- generic try : (val : error(@a, byte[:]) -> void)
+pkg std =
+ type error(@a, @b) = union
+ `Success @a
+ `Failure @b
+ ;;
;;
-type error(@a, @b) = union
- `Success @a
- `Failure @b
-;;
-
-generic try = {val
- /*
- match val
- `Success v: -> v;;
- `Failure msg: die(msg);;
- ;;
- */
-}