Commits

Bryan O'Sullivan committed 20b808c

Switch to new mul function for Size

Comments (0)

Files changed (1)

Data/Text/Internal/Fusion/Size.hs

     , isEmpty
     ) where
 
+import Data.Text.Internal (mul)
 #if defined(ASSERTS)
 import Control.Exception (assert)
 #endif
 subtractSize _               _               = Unknown
 {-# INLINE subtractSize #-}
 
-mul :: Int -> Int -> Int
-mul m n
-    | m <= maxBound `quot` n = m * n
-    | otherwise              = overflowError
-{-# INLINE mul #-}
-
 mulSize :: Size -> Size -> Size
 mulSize (Between ma mb) (Between na nb) = Between (mul ma na) (mul mb nb)
 mulSize _               _               = Unknown