~      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}portable provisionalJohn Lato <jwlato@gmail.com> Safe-Inferred DThis is the primary class for structures that are to be considered 2foldable. A minimum complete definition provides  and .  Instances of , can be folded, and can be many and varied. $These functions are used heavily in  Data.ListLike. Left-associative fold Strict version of .  A variant of ) with no base case. Requires at least 1  list element. Right-associative fold Strict version of  Like , but with no starting value 4Combine the elements of a structure using a monoid.   =  id 8Map each element to a monoid, then combine the results )Monadic version of left fold, similar to . +A map in monad space, discarding results. ,Evaluate each action, ignoring the results.  Same as   ~.      portable provisionalJohn Lato <jwlato@gmail.com> Safe-InferredO An extension to ' for those data types that are capable &of dealing with infinite lists. Some  functions are capable Fof working with finite or infinite lists. The functions here require 3infinite list capability in order to work at all. <An infinite list of repeated calls of the function to args 1An infinite list where each element is the same ,Converts a finite list into a circular one ,The class implementing list-like functions. &It is worth noting that types such as    can be instances of @. Due to their specific ways of operating, they may not behave 2in the expected way in some cases. For instance,  may not increase Kthe size of a map if the key you have given is already in the map; it will &just replace the value already there. %Implementators must define at least:  singleton  head  tail  null or genericLength The empty list 1Creates a single-element list out of an element @Like (:) for lists: adds an element to the beginning of a list "Adds an element to the *end* of a . !Combines two lists. Like (++).  Extracts the first element of a . Extracts the last element of a . $Gives all elements after the head. 8All elements of the list except the last one. See also 0. "Tests whether the list is empty. Length of the list. See also T. 6Apply a function to each element, returning any other  valid .  will always be at least G as fast, if not faster, than this function and is recommended 6 if it will work for your purposes. See also @. Like 6, but without the possibility of changing the type of H the item. This can have performance benefits for things such as D ByteStrings, since it will let the ByteString use its native & low-level map implementation. !Reverse the elements in a list. 3Add an item between each element in the structure Flatten the structure. !;Map a function over the items and concatenate the results.  See also ". "Like !*, but without the possibility of changing C the type of the item. This can have performance benefits . for some things such as ByteString. #(True if any items satisfy the function $(True if all items satisfy the function %The maximum value of the list &The minimum value of the list 'BGenerate a structure with the specified length with every element ) set to the item passed in. See also X (2Takes the first n elements of the list. See also U. )2Drops the first n elements of the list. See also V *Equivalent to (( n xs, ) n xs) . See also W. +BReturns all elements at start of list that satisfy the function. ,?Drops all elements form the start of the list that satisfy the  function. -The equivalent of (+ f xs, , f xs) .The equivalent of - ( . f) /ASplit a list into sublists, each which contains equal arguments. M For order-preserving types, concatenating these sublists will produce # the original list. See also Q. 02All initial segments of the list, shortest first 1#All final segnemts, longest first 2=True when the first list is at the beginning of the second. 3=True when the first list is at the beginning of the second. 4ATrue when the first list is wholly containted within the second 5%True if the item occurs in the list 6-True if the item does not occur in the list 7BTake a function and return the first matching element, or Nothing % if there is no such element. 86Returns only the elements that satisfy the function. 9;Returns the lists that do and do not satisfy the function.  Same as (8 p xs, 8 ( . p) xs) :AThe element at 0-based index i. Raises an exception if i is out + of bounds. Like (!!) for lists. ;1Returns the index of the element, if it exists. <9Returns the indices of the matching elements. See also  > =DTake a function and return the index of the first matching element, + or Nothing if no element matches >=Returns the indices of all elements satisfying the function ?>Evaluate each action in the sequence and collect the results @A map in monad space. Same as ? .   See also A ALike @3, but without the possibility of changing the type L of the item. This can have performance benefits with some types. B4Removes duplicate elements from the list. See also L C9Removes the first instance of the element from the list.  See also M DAList difference. Removes from the first list the first instance 0 of each element of the second list. See '(\)' and N E;List union: the set of elements that occur in either list. E Duplicate elements in the first list will remain duplicate.  See also O. FAList intersection: the set of elements that occur in both lists.  See also P G>Sorts the list. On data types that do not preserve ordering, C or enforce their own ordering, the result may not be what  you expect. See also R. HEInserts the element at the last place where it is still less than or I equal to the next element. On data types that do not preserve E ordering, or enforce their own ordering, the result may not H be what you expect. On types such as maps, this may result in . changing an existing item. See also S. I@Converts the structure to a list. This is logically equivolent  to K1, but may have a more optimized implementation. J&Generates the structure from a list. K,Converts one ListLike to another. See also I. # Default implementation is fromListLike = map id LGeneric version of B MGeneric version of M NGeneric version of D OGeneric version of E PGeneric version of F QGeneric version of /. R3Sort function taking a custom comparison function SLike H), but with a custom comparison function TLength of the list UGeneric version of ( VGeneric version of ) WGeneric version of * XGeneric version of ' Y<Takes two lists and returns a list of corresponding pairs. ZDTakes two lists and combines them with a custom combining function P  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZP  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZP !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWX YZ   H !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZportable provisionalJohn Lato <jwlato@gmail.com> Safe-Inferred[An extension to ' for those data types that are similar to a ". Minimal complete definition is \ and ]. \Converts the structure to a  ] Converts a  to a list ^(Breaks a string into a list of strings _&Breaks a string into a list of words ` Joins lines a Joins words [\]^_`a[\]^_`a[\]^_`a[\]^_`aportable provisionalJohn Lato <jwlato@gmail.com> Safe-Inferredb&Returns True if all elements are True c$Returns True if any element is True dThe sum of the list eThe product of the list f>Converts a list of pairs into two separate lists of elements g!Converts to a MonadPlus instance h-List-like destructor (like Data.Maybe.maybe) bcdefgh YZbcdefgh bcdeYZf ghbcdefghportable provisionalJohn Lato <jwlato@gmail.com> Safe-InferrediAn extension to # for those data types that support I/$O. These functions mirror those in  System.IO for the most part. They /also share the same names; see the comments in  Data.ListLike for help importing them. DNote that some types may not be capable of lazy reading or writing. "Therefore, the usual semantics of  System.IO functions regarding laziness >may or may not be available from a particular implementation. Minimal complete definition:  hGetLine  hGetContents  hGet  hGetNonBlocking  hPutStr j(Reads a line from the specified handle k6Read entire handle contents. May be done lazily like    . l%Read specified number of bytes. See    for  particular semantics. mNon-blocking read. See   for more. nWriting entire data. o#Write data plus newline character. pRead one line q%Read entire content from stdin. See k. rWrite data to stdout. s-Write data plus newline character to stdout. t@Interact with stdin and stdout by using a function to transform % input to output. May be lazy. See   for more. uRead file. May be lazy. vWrite data to file. wAppend data to file. ijklmnopqrstuvwijklmnopqrstuvwijklmnopqrstuvwijklmnopqrstuvwportable provisionalJohn Lato <jwlato@gmail.com> Safe-Inferredx>Newtype wrapper around Data.ByteString.Lazy.Char8.ByteString, : this allows for ListLike instances with Char elements. {9Newtype wrapper around Data.ByteString.Char8.ByteString, : this allows for ListLike instances with Char elements. xyz{|}xyz{|}{|}xyzxyz{|}NoneNoneNoneNoneNoneNoneNoneportable provisionalJohn Lato <jwlato@gmail.com>NoneNoneportable provisional$John Goerzen <jgoerzen@complete.org>Noney  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_bcdefijklmnopqrstuvwxyz{|}ybcdeYZf ijklmnopqrstuvw{|}xyz !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWX[\]^_  !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~  ListLike-4.0.0Data.ListLike.FoldableLLData.ListLike.BaseData.ListLike.StringData.ListLike.UtilsData.ListLike.IOData.ListLike.CharString Control.MonadfoldMData.MapMap System.IO hGetContentshGethGetNonBlockinginteractData.ListLike.Text.TextData.ListLike.Text.TextLazyData.ListLike.TextData.ListLike.Vector.StorableData.ListLike.Vector.UnboxedData.ListLike.Vector.VectorData.ListLike.VectorData.ListLike.InstancesData.ListLike.Vector.Generic Data.ListLike FoldableLLfoldlfoldl'foldl1foldrfoldr'foldr1foldfoldMapmapM_ sequence_InfiniteListLikeiteraterepeatcycleListLikeempty singletonconssnocappendheadlasttailinitnulllengthmaprigidMapreverse intersperseconcat concatMaprigidConcatMapanyallmaximumminimum replicatetakedropsplitAt takeWhile dropWhilespanbreakgroupinitstails isPrefixOf isSuffixOf isInfixOfelemnotElemfindfilter partitionindex elemIndex elemIndices findIndex findIndicessequencemapM rigidMapMnubdelete deleteFirstsunion intersectsortinserttoListfromList fromListLikenubBydeleteBydeleteFirstsByunionBy intersectBygroupBysortByinsertBy genericLength genericTake genericDropgenericSplitAtgenericReplicatezipzipWith StringLiketoString fromStringlineswordsunlinesunwordsandorsumproductunzip toMonadPluslist ListLikeIOhGetLinehPutStr hPutStrLngetLine getContentsputStrputStrLnreadFile writeFile appendFileCharStringLazyCSLunCSL CharStringCSunCSbaseGHC.Baseid$fFoldableLL[]aghc-prim GHC.Classesnot $fListLike[]aStringmyLinesmyWords myUnlines myUnwordsmi64toi strict2lazy$fStringLikeCharStringLazy$fListLikeIOCharStringLazyChar$fListLikeCharStringLazyChar$fFoldableLLCharStringLazyChar$fMonoidCharStringLazy$fStringLikeCharString$fListLikeIOCharStringChar$fListLikeCharStringChar$fFoldableLLCharStringChar$fMonoidCharString$fStringLikeText$fListLikeIOTextChar$fListLikeTextChar$fFoldableLLTextChar isPrefixOf' isSuffixOf'$fStringLikeVector$fListLikeVectora$fFoldableLLVectora$fListLikeSeqa$fFoldableLLSeqa$fStringLikeSeq$fListLikeIOSeqChar$fListLikeIOArrayChar$fStringLikeArray$fListLikeArraye $fMonoidArray$fFoldableLLArraye$fStringLikeByteString$fListLikeIOByteStringWord8$fListLikeByteStringWord8$fFoldableLLByteStringWord8$fStringLikeByteString0$fListLikeIOByteStringWord80$fListLikeByteStringWord80$fFoldableLLByteStringWord80$fInfiniteListLike[]a$fStringLike[]$fListLikeIO[]Char $fStringLikev $fListLikeva$fFoldableLLva