Add Functor instance for boxed vectors
authorRoman Leshchinskiy <rl@cse.unsw.edu.au>
Thu, 23 Jun 2011 20:06:03 +0000 (20:06 +0000)
committerRoman Leshchinskiy <rl@cse.unsw.edu.au>
Thu, 23 Jun 2011 20:06:03 +0000 (20:06 +0000)
Data/Vector.hs

index 821e953..f44f755 100644 (file)
@@ -251,6 +251,10 @@ instance Monoid (Vector a) where
   {-# INLINE mconcat #-}
   mconcat = concat
 
+instance Functor Vector where
+  {-# INLINE fmap #-}
+  fmap = G.map
+
 -- Length information
 -- ------------------