X-Git-Url: http://git.megacz.com/?a=blobdiff_plain;f=Data%2FQueue.hs;h=6a06670f35288ab0d024f54fbb88c607fcab9410;hb=88b22778e7c06909683b493e037605a249ae37ad;hp=8db6df65ae0b338ee01f71f39479c929939f4ee8;hpb=b9f76ae04a6df4e7251e725c381588209773c0b3;p=ghc-base.git diff --git a/Data/Queue.hs b/Data/Queue.hs index 8db6df6..6a06670 100644 --- a/Data/Queue.hs +++ b/Data/Queue.hs @@ -23,13 +23,15 @@ module Data.Queue( listToQueue, queueToList ) where -#ifdef __HADDOCK__ -import Prelude -#endif +import Prelude -- necessary to get dependencies right +import Data.Typeable -- | The type of FIFO queues. data Queue a = Q [a] [a] [a] +#include "Typeable.h" +INSTANCE_TYPEABLE1(Queue,queueTc,"Queue") + -- Invariants for Q xs ys xs': -- length xs = length ys + length xs' -- xs' = drop (length ys) xs -- in fact, shared (except after fmap)