diff options
author | Ben Gamari <ben@smart-cactus.org> | 2017-10-19 13:25:02 -0400 |
---|---|---|
committer | Ben Gamari <ben@smart-cactus.org> | 2017-10-19 16:43:24 -0400 |
commit | 2ca8cf69c50f6fcae17fdcbbcad16227519e5d02 (patch) | |
tree | 4d9feb1ba4436ade598b7e0bdc9e03eb92cac6f8 | |
parent | b6204f70501ec4ce4015503421c8a83c6f0fa008 (diff) | |
download | haskell-2ca8cf69c50f6fcae17fdcbbcad16227519e5d02.tar.gz |
Add Functor Bag instance
-rw-r--r-- | compiler/utils/Bag.hs | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/compiler/utils/Bag.hs b/compiler/utils/Bag.hs index a027db23b7..af5caadb24 100644 --- a/compiler/utils/Bag.hs +++ b/compiler/utils/Bag.hs @@ -330,5 +330,8 @@ instance Data a => Data (Bag a) where dataTypeOf _ = mkNoRepType "Bag" dataCast1 x = gcast1 x +instance Functor Bag where + fmap = mapBag + instance Foldable.Foldable Bag where foldr = foldrBag |