From a594d5f4e806a711663c10de989fe58f08dd5b57 Mon Sep 17 00:00:00 2001 From: Neil Brown Date: Sat, 7 Jun 2008 20:13:36 +0000 Subject: [PATCH] Stopped the expression flattener from stopping on an unrecognised dyadic operator, and instead made it record the expression unflattened --- checks/ArrayUsageCheck.hs | 1 - 1 file changed, 1 deletion(-) diff --git a/checks/ArrayUsageCheck.hs b/checks/ArrayUsageCheck.hs index 4ed7a8a..195d65b 100644 --- a/checks/ArrayUsageCheck.hs +++ b/checks/ArrayUsageCheck.hs @@ -479,7 +479,6 @@ flatten e@(A.Dyadic m op lhs rhs) Just _ -> liftM2L (Divide 1) (flatten lhs) (return rhs') -- Can't deal with variable divisors, leave expression as-is: Nothing -> return [Scale 1 (e,0)] - | otherwise = throwError ("Unhandleable operator found in expression: " ++ show op) where -- liftM2L :: (Ord a, Ord b, Monad m) => (Set.Set a -> Set.Set b -> c) -> m [a] -> m [b] -> m [c] liftM2L f x y = liftM singleton $ liftM2 f (x >>= makeExpSet) (y >>= makeExpSet)