From 893bb509cdde7974fcc758dd6396ebc42230b698 Mon Sep 17 00:00:00 2001 From: Joey Hess Date: Sun, 9 Mar 2014 14:08:45 -0400 Subject: use Monoid instance for Ordering --- Utility/Misc.hs | 12 ------------ 1 file changed, 12 deletions(-) (limited to 'Utility') diff --git a/Utility/Misc.hs b/Utility/Misc.hs index 20007adad..9c19df833 100644 --- a/Utility/Misc.hs +++ b/Utility/Misc.hs @@ -109,18 +109,6 @@ massReplace vs = go [] vs go (replacement:acc) vs (drop (length val) s) | otherwise = go acc rest s -{- Given two orderings, returns the second if the first is EQ and returns - - the first otherwise. - - - - Example use: - - - - compare lname1 lname2 `thenOrd` compare fname1 fname2 - -} -thenOrd :: Ordering -> Ordering -> Ordering -thenOrd EQ x = x -thenOrd x _ = x -{-# INLINE thenOrd #-} - {- Wrapper around hGetBufSome that returns a String. - - The null string is returned on eof, otherwise returns whatever -- cgit v1.2.3