shithub: mc

Download patch

ref: 7f72d10792936c26a6c92ea4bd8489381c8ce789
parent: baf8c15face883eaf2d06a875dee6bbf73134913
author: Ori Bernstein <[email protected]>
date: Thu Jan 2 05:20:23 EST 2014

Add missing 'numcmp' function

--- a/libstd/cmp.myr
+++ b/libstd/cmp.myr
@@ -13,6 +13,16 @@
 	const strncmp	: (a : byte[:], b : byte[:], n : size -> order)
 ;;
 
+generic numcmp = {a, b
+	if a < b
+		-> `Before
+	elif a == b
+		-> `Equal
+	else
+		-> `After
+	;;
+}
+
 const strcmp = {a, b
 	var l
 	var i