shithub: mc

Download patch

ref: 781e188ad6426398558638dfa0984699d64ef413
parent: 2be6300162a3b32e4d82f71ed6772aa5feced897
author: Ori Bernstein <ori@eigenstate.org>
date: Wed Jun 21 19:07:48 EDT 2017

Move `canget()` to appropriate place.

--- a/lib/std/option.myr
+++ b/lib/std/option.myr
@@ -7,9 +7,3 @@
 	generic canget	: (o : option(@a) -> bool)
 ;;
 
-generic canget = {o
-	match o
-	| `None: -> false
-	| `Some _: -> true
-	;;
-}
--- a/lib/std/try.myr
+++ b/lib/std/try.myr
@@ -23,6 +23,13 @@
 	;;
 }
 
+generic canget = {o
+	match o
+	| `None: -> false
+	| `Some _: -> true
+	;;
+}
+
 generic get = {v
 	match v
 	| `Some x:	-> x