vljJ      !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIUses GHC extensions experimentalNone/J'A map of keys to values. The keys are K types but are stored as Ls  so any keys with the same L/ value are treated as the same. The aim is to  provide typesafe indexing. &No subtrees should be empty. Returns M if one is. NRemove empty subtrees. Join a key so that an J of J s becomes an  J.  # newtype ID = ID Int deriving Enum 4 emm :: EnumMapMap (K Int) (EnumMapMap (K ID) Bool) & res :: EnumMapMap (Int :& K ID) Bool  res = joinKey emm  is the opposite of &. 6 emm = empty :: EnumMapMap (Int :& Int :& K ID) Bool) " emm == joinKey $ splitKey d2 emm Join a key so that an J of J s becomes an  J<. The unsafe version does not check for empty subtrees, so  it is faster. # newtype ID = ID Int deriving Enum 4 emm :: EnumMapMap (K Int) (EnumMapMap (K ID) Bool) & res :: EnumMapMap (Int :& K ID) Bool  res = unsafeJoinKey emm  The empty J. Is the J empty? FSubmaps can never be empty, so the following should always hold true: . emm :: EnumMapMap (Int :& Int :& K ID) Bool)  null $ splitKey x emm == False Number of elements in the J. The expression ( f k emm) alters the value at k, or absence thereof.  8 can be used to insert, delete, or update a value in an J. &Map a function over all values in the J. Map a function over all key/value pairs in the J. Fold the values in the J# using the given right-associative  binary operator  Fold the keys and values in the J# using the given right-associative  binary operator.  Convert the J to a list of key/ value pairs.  Create a J from a list of key/ value pairs. ,List of elements in ascending order of keys  List of keys The  of the keys. J keys can be converted into   keys using , and back again using .  Build an J from an  EnumMapSet and a function which for each  key computes it's value The (left-biased) union of two Js.  It prefers the first J& when duplicate keys are encountered. The union of a list of maps. %The union with a combining function. %The union with a combining function. Difference between two Js (based on keys). &Difference with a combining function. &Difference with a combining function. &The (left-biased) intersection of two J (based on keys). ,The intersection with a combining function. ,The intersection with a combining function. Convert a key terminated with K into one terminated with S.  k = 1 :& 2 :& 'K' 3  toS k == 1 :& 2 :& 'S' 3 Convert a key terminated with S into one terminated with K.  s = 1 :& 2 :& S 3  toK s == 1 :& 2 :& K 3 The intersection of an J and an  EnumMapSet. If a key is D present in the EnumMapSet then it will be present in the resulting  J. Works with  EnumMapSets that are submaps of the  J. The difference between an J and an  EnumMapSet . If a key  is present in the  EnumMapSet' it will not be present in the result. O!k1 should be a prefix of k2. If k1 ~ k2 then the O will be  v. ? Result (K ID1) (ID1 :& K ID2) v ~ EnumMapMap (K ID2) v , Result (ID1 :& K ID2) (ID1 :& K ID2) v ~ v 1 Result (ID1 :& K ID2) (K ID1) v -- ERROR 1 Result (ID2 :& K ID1) (ID1 :& K ID2) -- ERROR Is the key present in the J? An J with one element 8 singleton (5 :& K 3) "a" == fromList [(5 :& K 3, "a")] E singleton (K 5) $ singleton (K 2) "a" == fromList [(5 :& K 3, "a")] !$Lookup up the value at a key in the J.  " emm = fromList [(3 :& K 1, "a")] # lookup (3 :& K 1) emm == Just "a" " lookup (2 :& K 1) emm == Nothing .If the given key has less dimensions then the J then a submap  is returned. > emm2 = fromList [(3 :& 2 :& K 1, "a"), (3 :& 2 :& K 4, "a")] D lookup (3 :& K 2) emm2 == Just $ fromList [(K 1, "a"), (K 4, "a")] "Insert a new key/value pair into the J. Can also insert submaps. #<Insert with a combining function. Can also insert submaps. $<Insert with a combining function. Can also insert submaps. %Remove a key and it's value from the J. If the key is not  present the original J is returned. &Split a key so that an J becomes an J of  Js.  # newtype ID = ID Int deriving Enum . emm = empty :: EnumMapMap (Int :& K ID) Bool  res :: EnumMapMap (K ID) Bool & res = lookup (K 5) $ splitKey d1 emm FIf the level is too high then the compilation will fail with an error B emm = empty :: EnumMapMap (Int :& Int :& K Int) Bool -- 3 levels 8 res1 = splitKey d4 emm -- ERROR! Instance not found... 8 res2 = splitKey d3 emm -- ERROR! Instance not found...  res3 = splitKey d2 emm -- Good '!Multiple keys are joined by the (') constructor. ! multiKey :: Int :& Int :& K Int  multiKey = 5 :& 6 :& K 5 )Split after 1 key. ( emm :: EnumMapMap (T1 :& T2 :& K T3) v B splitKey d1 emm :: EnumMapMap (T1 :& K T2) (EnumMapMap (K T3) v) *Split after 2 keys. ( emm :: EnumMapMap (T1 :& T2 :& K T3) v B splitKey d1 emm :: EnumMapMap (K T1) (EnumMapMap (T2 :& K T3) v) PP+ is used to walk down the tree to find the J to actually  change. If the new J is null then it's removed from the containing  Q. RSee IntMap% documentation for an explanation of R. sSJTN UVWXYZO !"#$%[\]^&_`ab'(cdefQghi)*+,-./012jPklRmnopqrstuvwxyz{|}~`SJTN UVWXYZO !"#$%[\]^&_`ab'(cdefQghi)*+,-./012klRopqrsuwxyz{}~=S JTN UVWXYZO !"#$%[\]^&_`ab'(cdefQihg)*+,-./012jPklRmnopqrstuvwxyz{|}~Uses GHC extensions experimentalNone3Keys are terminated with the 3 type.  singleKey :: S Int  singleKey = S 5 9Lookup a subtree in an 5. / ems = fromList [1 :& 2 :& K 3, 1 :& 2 :& K 4] . lookup (1 :& K 2) ems == fromList [K 3, K 4] C lookup (1 :& 2 :& K 3) -- ERROR: Use 'member' to check for a key. ?? f s! is the set obtained by applying f to each element of s. It'>s worth noting that the size of the result may be smaller if,  for some (x,y), x /= y && f x == f y -3456789:;<=>?@ABCDE J'(3456789:;<=>?@ABCDE)3456789:;<=>?@ABCDEUses GHC extensions experimentalNone'(3456789:;<=>?@ABCDE534'(6789:;<=@AB?>DCEUses GHC extensions experimentalNoneFKeys are terminated with the F type  singleKey :: K Int  singleKey = K 5 FG6J  !"#$%&'()*+,-./012FG5'(FG)*+,-./012! "#$%  &FGUses GHC extensions experimentalNoneHKeys are terminated with the H type  singleKey :: K Int  singleKey = K 5 HI6J  !"#$%&'()*+,-./012HI5'(HI)*+,-./012! "#$%  &HI      !"#$%&'()*+,-.//0123456789::  ') (*- ;;;;<=>?@AB@ACDEFGHIJKLMNOPQRSTUUVVWXYZ[\]^_`abcdefghijklmnopqrstuvwxyz{|}~[\]gikvwvwenummapmap-0.4.0Data.EnumMapMap.StrictData.EnumMapSetData.EnumMapMap.LazyData.EnumMapMap.BaseData EnumMapSetData.EnumMapSet.Base emptySubTreesjoinKey unsafeJoinKeyemptynullsizealtermap mapWithKeyfoldr foldrWithKeytoListfromListelemskeyskeysSetfromSetunionunions unionWith unionWithKey differencedifferenceWithdifferenceWithKey intersectionintersectionWithintersectionWithKeytoStoK intersectSet differenceSetmember singletonlookupinsert insertWith insertWithKeydeletesplitKey:&d1d2d3d4d5d6d7d8d9d10SK EnumMapMapbaseGHC.EnumEnumghc-prim GHC.TypesIntTrue removeEmptiesResultalter_EMM mergeWithKey'IsKeyemptySubTrees_equalnequalHasSKeySkeySubKeySSubKeyPlusIsSplitHeadTailNZMaskPrefixKeyNatNilTipBin insertWith_ mapWithKey_ foldrWithKey_equalEnequalE natFromInt intFromNatshiftRLshiftLLjoinjoinDbinbinDtipzeronomatchmatchmaskmaskWshorter branchMaskhighestBitMask foldlStrict $fNFData:&$fNFDataEnumMapMap$fShowEnumMapMap$fMonoidEnumMapMap$fFunctorEnumMapMap$fEqEMM$fEqEnumMapMap $fIsKey:& $fSubKeyS:&:& $fSubKey:&:&v $fHasSKey:& $fIsSplit:&NKCCEMSBitMap insertSubinsertBMdeleteBM suffixBitMask prefixBitMaskprefixOfsuffixOfbitmapOfSuffixbitmapOfbitcountindexOfTheOnlyBit lowestBitMaskrevNat foldrBits $fSubKeySS() $fSubKeyS:&() $fHasSKeyS$fIsKeySKSCmember_lookup_insert_insertWKdelete_fromSet_ intersectSet_differenceSet_ $fSubKeySKS $fSubKeyS:&S $fSubKeyKKv $fSubKeyK:&v $fIsSplit:&Z $fHasSKeyK $fNFDataK$fIsKeyK