tK5[55.5.0+dev0-2025-04-28/*MoreLabelsӱ'HashtblA@!tB;!a@!b@@B@A&Stdlib'Hashtbl!tC@C@@@@OO@BB@@@;../../stdlib/moreLabels.mliO  O  @@@@*MoreLabels@@A@&createc&random&optionL$bool@@@X@@@`@#int@@@Y*MoreLabels'Hashtbl!t!a@cC@Z!b@eC@[@@@^@@_@@a@<R  =S A a@@;A@@%cleard@*MoreLabels'Hashtbl!t!a@nC@f!b@pC@g@@@j$unit@@@k@@l@ezfz@@dB@@%resete@*MoreLabels'Hashtbl!t!a@yC@q!b@{C@r@@@u)@@@v@@w@~~@@C@@$copyf@*MoreLabels'Hashtbl!t!a@C@|!b@C@}@@@*MoreLabels'Hashtbl!t@@@@@@<@@D@@#addg@*MoreLabels'Hashtbl!t!a@C@!b@C@@@@#key$data@@@@@@@@@@mom@@E@@$findh@*MoreLabels'Hashtbl!t!a@C@!b@C@@@@@ @@@@@EGEh@@F@@(find_opti@*MoreLabels'Hashtbl!t!a@C@!b@C@@@@@' @@@@@@@@;<@@:G@@(find_allj@*MoreLabels'Hashtbl!t!a@C@!b@C@@@@@$listƠ@@@@@@@@gh@@fH@@#memk@*MoreLabels'Hashtbl!t!a@C@!b@C@@@@@w@@@@@@@@@@I@@&removel@*MoreLabels'Hashtbl!t!a@C@Ǡ!b@C@@@@@W@@@@@@@@>@@J@@'replacem@*MoreLabels'Hashtbl!t!a@C@Ӡ!b@C@@@@#key$data@@@@@@@@@@)@@K@@$itern!f#key!a@C@$data!b@C@@@@@@@@@*MoreLabels'Hashtbl!t!@@@@@@@@@@@$bd%b@@#L@@2filter_map_inplaceo!f#key!a@C@$data!b@C@6 @@@@@@@@*MoreLabels'Hashtbl!t!@@@@@@@@@@@]""^"`"j@@\M@@$foldp!f#key!a@ C@$data!b@ C@ @#acc@ C@ @@ @@ @@ @*MoreLabels'Hashtbl!t$@@@ $init@@ @@ @@ @###$:@@N@@&lengthq@*MoreLabels'Hashtbl!t!a@ C@ !b@ C@ @@@ @@@ @@ @''''@@O@@)randomizer@l@@@ q@@@ @@ @((((@@P@@-is_randomizeds@@@@ @@@ @@ !@,Z,\,Z,|@@Q@@'rebuildt&random@@@ "@@@ ,@*MoreLabels'Hashtbl!t!a@ /C@ #!b@ 1C@ $@@@ '*MoreLabels'Hashtbl!t@@@ *@@ +@@ -@&--'-H-f@@%R@@*statisticsuC;@@,num_bindingsv@@@@@ 390K0O:0K0a@@8T@+num_bucketsw@@#@@@ 6F00G00@@EU@1max_bucket_lengthx@@0@@@ 9S1 1T1 1%@@RV@0bucket_histogramy@@%arrayC@@@ <@@@ >g1Z1^h1Z1y@@fW@@@A&Stdlib'Hashtbl*statistics@@@ A@@@@v0 0"w"2427@@@@uS@A@%statsz@*MoreLabels'Hashtbl!t!a@ jD@ b!b@ lD@ c@@@ f*MoreLabels'Hashtbl*statistics@@@ g@@ h@$292;$292_@@X@@&to_seq@*MoreLabels'Hashtbl!t!a@ D@ m!b@ D@ n@@@ q&Stdlib#Seq!t@@@@ @@@ @@ @,3;3=,3;3f@@Y@@+to_seq_keys@*MoreLabels'Hashtbl!t!a@ D@ @@ @@@ &Stdlib#Seq!t@@@ @@ @744745"@@Z@@-to_seq_values@*MoreLabels'Hashtbl!t@@ !b@ D@ @@@ &Stdlib#Seq!t@@@ @@ @+;5`5b,;5`5@@*[@@'add_seq@*MoreLabels'Hashtbl!t!a@ D@ !b@ D@ @@@ @&Stdlib#Seq!t@@@@ @@@ @@@ @@ @@ @f?55g?55@@e\@@+replace_seq@*MoreLabels'Hashtbl!t!a@ D@ !b@ D@ @@@ @&Stdlib#Seq!t@@@@ @@@ =@@@ @@ @@ @C6K6MC6K6@@]@@&of_seq@&Stdlib#Seq!t@!a@ D@ Ϡ@!b@ D@ @@ @@@ *MoreLabels'Hashtbl!t@@@ @@ @G66G67@@^@@*HashedTypeE!tD;@@A@@@@@oc@A@!tG;!a@ @AcA@O@B@@@O@9@?P@9@I@@@@Nd@A@&create@<@@@ *MoreLabels'Hashtbl!S!t!a@ H@ @@@ @@ @r@J@Ps@J@h@@qe@@%clear@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ 1@@@ @@ @@i@o@i@@@f@@%reset@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ T@@@ @@ @@@@@@@g@@$copy@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ *MoreLabels'Hashtbl!S!t@@@ @@ @@@@@@@h@@#add@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ #key*MoreLabels'Hashtbl!S#key@@@ $data@@@ @@ @@ @@ @@@@A @@i@@&remove@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ @*MoreLabels'Hashtbl!S#key@@@ @@@ @@ @@ @KA ALA A2@@Jj@@$find@*MoreLabels'Hashtbl!S!t!a@ H@ @@@ @*MoreLabels'Hashtbl!S#key@@@ @@ @@ @wA3A9xA3AU@@vk@@(find_opt@*MoreLabels'Hashtbl!S!t!a@ )H@ @@@ "@*MoreLabels'Hashtbl!S#key@@@ #@@@ %@@ &@@ '@AVA\AVA@@l@@(find_all@*MoreLabels 'Hashtbl!S!t!a@ 3H@ *@@@ ,@*MoreLabels 'Hashtbl!S#key@@@ -t @@@ /@@ 0@@ 1@AAAA@@m@@'replace@*MoreLabels 'Hashtbl!S!t!a@ =H@ 4@@@ 6#key*MoreLabels 'Hashtbl!S#key@@@ 7$data@@@ 8@@ 9@@ :@@ ;@AAAB@@n@@#mem@*MoreLabels'Hashtbl!S!t!a@ FH@ >@@@ @@*MoreLabels'Hashtbl!S#key@@@ A(@@@ B@@ C@@ D@BBBCBB$@@Ao@@$iter!f#key*MoreLabels'Hashtbl!S#key@@@ G$data!a@ RH@ H @@@ I@@ J@@ K@*MoreLabels'Hashtbl!S!t@@@ M@@@ N@@ O@@ P@B%B+B%Bd@@p@@2filter_map_inplace!f#key*MoreLabels'Hashtbl!S#key@@@ S$data!a@ _H@ T @@@ V@@ W@@ X@*MoreLabels'Hashtbl!S!t@@@ Z^@@@ [@@ \@@ ]@BeBkBB@@q@@$fold!f#key*MoreLabels'Hashtbl!S#key@@@ `$data!a@ lH@ a@#acc@ nH@ b@@ c@@ d@@ e@*MoreLabels'Hashtbl!S!t@@@ g$init@@ h@@ i@@ j@BBBC5@@r@@&length@*MoreLabels'Hashtbl!S!t!a@ uH@ o@@@ q@@@ r@@ s@'C6C<(C6CT@@&s@@%stats@*MoreLabels'Hashtbl!S!t!a@ |H@ v@@@ x*MoreLabels'Hashtbl*statistics@@@ y@@ z@OCUC[PCUCx@@Nt@@&to_seq@*MoreLabels'Hashtbl!S!t!a@ H@ }@@@ &Stdlib!#Seq!t@*MoreLabels 'Hashtbl!S#key@@@ @#@@ @@@ @@ @CCCC@@u@@+to_seq_keys@*MoreLabels"'Hashtbl!S!t@@ @@@ &Stdlib$#Seq!t*MoreLabels#'Hashtbl!S#key@@@ @@@ @@ @CCCC@@v@@-to_seq_values@*MoreLabels%'Hashtbl!S!t!a@ H@ @@@ &Stdlib&#Seq!t@@@ @@ @DDDD@@@w@@'add_seq@*MoreLabels''Hashtbl!S!t!a@ H@ @@@ @&Stdlib)#Seq!t@*MoreLabels('Hashtbl!S#key@@@ @%@@ @@@ *@@@ @@ @@ @ &D[Da 'D[D@@ %x@@+replace_seq@*MoreLabels+'Hashtbl!S!t!a@ H@ @@@ @&Stdlib-#Seq!t@*MoreLabels,'Hashtbl!S#key@@@ @%@@ @@@  .@@@ @@ @@ @ hDD iDD@@ gy@@&of_seq@&Stdlib0#Seq!t@*MoreLabels/'Hashtbl!S#key@@@ @!a@ H@ @@ @@@ *MoreLabels1'Hashtbl!S!t@@@ @@ @ DE DE(@@ z@@@@ @@ EBEI@ {@@ӱ$MakeCI@!HJܑ~+K;@@@A!t@@@@@@@ EE EE@@@@ }@A@,K;!a@1K@/@A@A&Stdlib'Hashtbl$Make.!tK@-@@@O@B@@@ EE EE@@@@ ~@A@-@ A@@@ /@@@ @@ @@@.@ {@@@  F@@@ @@@u@r@q/@g@@@@@@@@@`@]@\0@(R@@@,V@@@@@@C@@@?1@65@@@/{@@@%>3@@@@@@@@@@"@@2@L@@@@@@@F@@@@@@@@@@3@_@@@@)@@@@@@@@@@4@n@@@@8@@@ʠ@@@@@@@@@@5@@@@@K@@@ K@@@@@@@@@@6@@@@`@@@@@@@@@@@@@@@7@|@@@@u@@@ E@@@@@@@@m@j@i8hf@@@[Y@@@@@@@@̠b@@@@@@@@@@@H@E@D9CA@@@64.7@@@@@@@@=@@@@@@@@@@@#@ @:@@@@  @@@@@@@@@@@@@@@@@@@;@ @@@@@@@@@@@<@@@@@@@@@@@@=@(@@@K#Seq!t@@@@@@@@@@@@@@@>@C@@@f#Seq!t@@@@@@@@@@@?@X@@@{#Seq!t@@@@@@v@s@r@@jh@@@@#Seq!t@?@@@@{@@@@@r@@@@@@@@U@R@QA@G@@@@#Seq!t@`@@@@Z@@@@@@@@@@@@@4@1@0B@#Seq!t@{@@@@#@@@@@'@@@@@@@@@@ EE@ @@@0SeededHashedTypeGM!tDL;@@ A@@@@@ HH HH@@@@ @@A@%equalE@*MoreLabels3'Hashtbl0SeededHashedType!t@@@@*MoreLabels4'Hashtbl0SeededHashedType!t@@@ 5@@@@@@@@ HH HH@@ A@@+seeded_hashF@ 6@@@@*MoreLabels7'Hashtbl0SeededHashedType!t@@@ 8@@@@@@@@ II II<@@ B@@@@ HWHY JJ@ C@@'SeededS`P#keyHN;@@ =A@@@@@ 'KK  (KK@@@@ &D@A@!tIO;!a@@A KA@O@B@@@ 7KK 8KK"@@@@ 6E@A@&createJ&random 5 29@@@@@@$@ 1:@@@*MoreLabels;'Hashtbl'SeededS!t!a@'P@ @@@"@@#@@%@ gK#K) hKkK@@ fF@@%clearK@*MoreLabels<'Hashtbl'SeededS!t!a@.P@(@@@* &=@@@+@@,@ KK KK@@ G@@%resetL@*MoreLabels>'Hashtbl'SeededS!t!a@5P@/@@@1 I?@@@2@@3@ KK KK@@ H@@$copyM@*MoreLabels@'Hashtbl'SeededS!t!a@=P@6@@@8*MoreLabelsA'Hashtbl'SeededS!t@@@:@@;@ KK KK@@ I@@#addN@*MoreLabelsB'Hashtbl'SeededS!t!a@GP@>@@@@#key*MoreLabelsC'Hashtbl'SeededS#key@@@A$data D@@@B@@C@@D@@E@ KK KL@@ J@@&removeO@*MoreLabelsE'Hashtbl'SeededS!t!a@PP@H@@@J@*MoreLabelsF'Hashtbl'SeededS#key@@@K G@@@L@@M@@N@ @LL ALL?@@ ?K@@$findP@*MoreLabelsH'Hashtbl'SeededS!t!a@XP@Q@@@S@*MoreLabelsI'Hashtbl'SeededS#key@@@T@@U@@V@ lL@LF mL@Lb@@ kL@@(find_optQ@*MoreLabelsJ'Hashtbl'SeededS!t!a@bP@Y@@@[@*MoreLabelsK'Hashtbl'SeededS#key@@@\ @@@^@@_@@`@ LcLi LcL@@ M@@(find_allR@*MoreLabelsL'Hashtbl'SeededS!t!a@lP@c@@@e@*MoreLabelsM'Hashtbl'SeededS#key@@@f iN@@@h@@i@@j@ LL LL@@ N@@'replaceS@*MoreLabelsO'Hashtbl'SeededS!t!a@vP@m@@@o#key*MoreLabelsP'Hashtbl'SeededS#key@@@p$data Q@@@q@@r@@s@@t@LLLM@@O@@#memT@*MoreLabelsR'Hashtbl'SeededS!t!a@P@w@@@y@*MoreLabelsS'Hashtbl'SeededS#key@@@zT@@@{@@|@@}@7MM8MM+@@6P@@$iterU!f#key*MoreLabelsU'Hashtbl'SeededS#key@@@$data!a@P@ V@@@@@@@@*MoreLabelsW'Hashtbl'SeededS!t@@@X@@@@@@@@wM,M2xM,Mk@@vQ@@2filter_map_inplaceV!f#key*MoreLabelsY'Hashtbl'SeededS#key@@@$data!a@P@ @@@@@@@@*MoreLabelsZ'Hashtbl'SeededS!t@@@S[@@@@@@@@MlMrMM@@R@@$foldW!f#key*MoreLabels\'Hashtbl'SeededS#key@@@$data!a@P@@#acc@P@@@@@@@@*MoreLabels]'Hashtbl'SeededS!t@@@$init@@@@@@@MMMN<@@S@@&lengthX@*MoreLabels^'Hashtbl'SeededS!t!a@P@@@@_@@@@@@N=NCN=N[@@T@@%statsY@*MoreLabels`'Hashtbl'SeededS!t!a@P@@@@*MoreLabelsa'Hashtbl*statistics@@@@@@DN\NbEN\N@@CU@@&to_seqZ@*MoreLabelsb'Hashtbl'SeededS!t!a@P@@@@&Stdlibd#Seq!t@*MoreLabelsc'Hashtbl'SeededS#key@@@@#@@@@@@@@NNNN@@~V@@+to_seq_keys[@*MoreLabelse'Hashtbl'SeededS!t@@@@@&Stdlibg#Seq!t*MoreLabelsf'Hashtbl'SeededS#key@@@@@@@@@NNNN@@W@@-to_seq_values\@*MoreLabelsh'Hashtbl'SeededS!t!a@P@@@@&Stdlibi#Seq!t@@@@@@O OO O4@@X@@'add_seq]@*MoreLabelsj'Hashtbl'SeededS!t!a@P@@@@@&Stdlibl#Seq!t@*MoreLabelsk'Hashtbl'SeededS#key@@@Ҡ@%@@@@@m@@@@@@@@OOOUOOO@@Y@@+replace_seq^@*MoreLabelsn'Hashtbl'SeededS!t!a@P@@@@@&Stdlibp#Seq!t@*MoreLabelso'Hashtbl'SeededS#key@@@ޠ@%@@@@@q@@@@@@@@]OO^OO@@\Z@@&of_seq_@&Stdlibs#Seq!t@*MoreLabelsr'Hashtbl'SeededS#key@@@砠@!a@P@@@@@@*MoreLabelst'Hashtbl'SeededS!t@@@@@@OOOP@@[@@@@JJP6P=@\@@ӱ*MakeSeededQ@!HaRS;@@@A!t@@@i@@@@PPPP@@@@^@A@S;!a@S@m@A@A'Hashtbl*MakeSeeded+!tS@@@@hO@B@@@PPPQ @@@@_@A@Ԡ<@@@g@@@f@@@@e5@@@d@@c@@b@@@@ @@@a@@@`@@_@z@w@v@l@@@^ @@@]@@\@e@b@a@'W@@@[+[@@@Z@@Y@H@E@D@5:@@@X4@@@W*C-@@@V@@U@@T@@S@'@$@#@K@@@R@@@@Q@@@@P@@O@@N@ @@@^@@@M@)@@@L@@K@@J@@@@m@@@I@8@@@HϠ@@@G@@F@@E@@@@@@@D@K@@@C@@@B@@A@@@@@@@@@@?_@@@>@@@=@@<@@;@@:@@@@@@@9@t@@@8@@@7@@6@@5@p@m@lki@@@4^\@@@3@@2@@1@ɠe@@@0@@@/@@.@@-@K@H@GFD@@@,971:@@@+@@*@@)@@@@@(@@@'@@&@@%@&@#@"!@@@$@  @@#@@"@@!@@@@ @@@@@@@@@@ @@@ @@@@@@@@@@@@@@@@@@@@@%@@@C#Seq!t@@@@@@@@@@@@@@@@@@@@^#Seq!t@@@@@@@@@@@@U@@@ s#Seq!t@@@ @@ @y@v@u@gk@@@ @#Seq!t@=@@@ @~@@@@@j@@@@@@@@X@U@T@J@@@@#Seq!t@^@@@@]@@@@@@@@@@@@@7@4@3@#Seq!t@y@@@@&@@@@@*@@@@@@@@@@PP@`@@@$hash@!a@nT@jv@@@k@@l@TTTT0@@a@@+seeded_hash@w@@@o@!a@uT@px@@@q@@r@@s@U+U-U+UO@@b@@*hash_param@y@@@v@z@@@w@!a@~T@x{@@@y@@z@@{@@|@$UU$UU@@c@@1seeded_hash_param@|@@@@}@@@@~@@@@!a@T@ @@@@@@@@@@@@07Z1Z317Z1Zi@@/d@@@@4c995ee@3e@@@ӱ#MapT@+OrderedTypeV!tU;@@`A@@@@@JiiKii@@@@If@A@'compare@*MoreLabels#Map+OrderedType!t@@@@*MoreLabels#Map+OrderedType!t@@@Q@@@@@@@@tjj ujj&@@sg@@@@xiiykk@wh@@!SY#keyW;@@A@@@@@lblhlblp@@@@i@A@!tX;!a@@AA@I@B@@@llll@@@@j@A@%empty*MoreLabels#Map!S!t!a@Y@@@@@llll@@k@@#add#key*MoreLabels#Map!S#key@@@$data!a@Y@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t!@@@@@@@@@@mm!mmL@@l@@+add_to_list#key*MoreLabels#Map!S#key@@@$data!a@Y@@*MoreLabels#Map!S!t@@@@@@*MoreLabels#Map!S!t,@@@@@@@@@@@@@>oo?ooX@@=m@@&update#key*MoreLabels#Map!S#key@@@!f@N!a@Y@@@@Y @@@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t'@@@@@@@@@@p'p-p'pn@@n@@)singleton@*MoreLabels#Map!S#key@@@@!a@Y@*MoreLabels#Map!S!t@@@@@@@@rrrs@@o@@&remove@*MoreLabels#Map!S#key@@@@*MoreLabels#Map!S!t!a@Y@@@@*MoreLabels#Map!S!t@@@@@@@@ssss@@p@@%merge!f@*MoreLabels#Map!S#key@@@@!a@Y@@@@@ !b@Y@@@@!c@Y@@@@@@@@@@@*MoreLabels#Map!S!t-@@@@*MoreLabels#Map!S!t/@@@*MoreLabels#Map!S!t1@@@@@@@@@@Yuu ZuQum@@Xq@@%union!f@*MoreLabels#Map!S#key@@@@!a@Y@@o @@@@@@@@@@*MoreLabels#Map!S!t@@@@*MoreLabels#Map!S!t*@@@*MoreLabels#Map!S!t7@@@@@@@@@@ w*w0 w*ws@@r@@(cardinal@*MoreLabels#Map!S!t!a@Y@@@@@@@@@@yyyy@@s@@(bindings@*MoreLabels#Map!S!t!a@Y@ @@@ @*MoreLabels#Map!S#key@@@ @@@ @@@@@@zz#zzH@@t@@+min_binding@*MoreLabels#Map!S!t!a@Y@@@@@*MoreLabels#Map!S#key@@@@@@@@@7&{S{Y8&{S{|@@6u@@/min_binding_opt@*MoreLabels#Map!S!t!a@$Y@@@@F@*MoreLabels#Map!S#key@@@@@@@@@!@@"@l,|E|Km,|E|y@@kv@@+max_binding@*MoreLabels#Map!S!t!a@,Y@%@@@'@*MoreLabels#Map!S#key@@@(@@@)@@*@2}9}?2}9}b@@w@@/max_binding_opt@*MoreLabels#Map!S!t!a@6Y@-@@@/@*MoreLabels#Map!S#key@@@0@@@1@@@3@@4@7}}7}~@@x@@&choose@*MoreLabels#Map!S!t!a@>Y@7@@@9@*MoreLabels#Map!S#key@@@:@@@;@@<@<~~<~~@@y@@*choose_opt@*MoreLabels#Map!S!t!a@HY@?@@@A@*MoreLabels#Map!S#key@@@B@@@C@@@E@@F@6B7B@@5z@@$find@*MoreLabels#Map!S#key@@@I@*MoreLabels#Map!S!t!a@PY@J@@@L@@M@@N@bJcJ@@a{@@(find_opt@*MoreLabels#Map!S#key@@@Q@*MoreLabels#Map!S!t!a@ZY@R@@@T @@@V@@W@@X@NzNz@@|@@*find_first!f@*MoreLabels#Map!S#key@@@[@@@\@@]@*MoreLabels#Map!S!t!a@fY@^@@@`@*MoreLabels#Map!S#key@@@a@@@b@@c@@d@SHNSH@@}@@.find_first_opt!f@*MoreLabels#Map!S#key@@@g@@@h@@i@*MoreLabels#Map!S!t!a@tY@j@@@l@*MoreLabels#Map!S#key@@@m@@@n@@@p@@q@@r@&_x~'_x@@%~@@)find_last!f@*MoreLabels#Map!S#key@@@u,@@@v@@w@*MoreLabels#Map!S!t!a@Y@x@@@z@*MoreLabels#Map!S#key@@@{@@@|@@}@@~@mene@@l@@-find_last_opt!f@*MoreLabels#Map!S#key@@@s@@@@@@*MoreLabels#Map!S!t!a@Y@@@@@*MoreLabels#Map!S#key@@@@@@@@@@@@@@kk&@@@@$iter!f#key*MoreLabels#Map!S#key@@@$data!a@Y@@@@@@@@@*MoreLabels#Map!S!t@@@@@@@@@@@tTZtT@@@@$fold!f#key*MoreLabels#Map!S#key@@@$data!a@Y@@#acc@Y@@@@@@@@*MoreLabels#Map!S!t@@@$init@@@@@@@;z<{@@:@@#map!f@!a@Y@!b@Y@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t!@@@@@@@@rs=@@q@@$mapi!f@*MoreLabels#Map!S#key@@@@!a@Y@!b@Y@@@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t!@@@@@@@@@@@@&filter!f@*MoreLabels#Map!S#key@@@@!a@Y@@@@@@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t&@@@@@@@@OUO@@@@*filter_map!f@*MoreLabels#Map!S#key@@@@!a@Y@!b@Y@@@@@@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t"@@@@@@@@EF@@D@@)partition!f@*MoreLabels#Map!S#key@@@@!a@Y@S@@@@@@@@*MoreLabels#Map!S!t@@@@*MoreLabels#Map!S!t*@@@젠@*MoreLabels#Map!S!t9@@@@@@@@@@!@@@@%split@*MoreLabels#Map!S#key@@@@*MoreLabels#Map!S!t!a@Y@@@@@*MoreLabels#Map!S!t@@@@̠@@@@*MoreLabels#Map!S!t-@@@@@@@@@@.4.e@@@@(is_empty@*MoreLabels#Map!S!t!a@ Y@@@@@@@@@@8>8X@@@@#mem@*MoreLabels#Map!S#key@@@ @*MoreLabels#Map!S!t!a@Y@ @@@ )@@@@@@@@CD@@B@@%equal#cmp@!a@ Y@@E@@@@@@@@*MoreLabels#Map!S!t@@@@*MoreLabels#Map!S!t*@@@h@@@@@@@@@@X@@@@'compare#cmp@!a@.Y@!@{@@@"@@#@@$@*MoreLabels#Map!S!t@@@&@*MoreLabels#Map!S!t*@@@(@@@)@@*@@+@@,@\b\@@@@'for_all!f@*MoreLabels#Map!S#key@@@/@!a@:Y@0@@@1@@2@@3@*MoreLabels#Map!S!t@@@5@@@6@@7@@8@:@:r@@@@&exists!f@*MoreLabels#Map!S#key@@@;@!a@FY@< @@@=@@>@@?@*MoreLabels#Map!S!t@@@A@@@B@@C@@D@9:(@@8@@'to_list@*MoreLabels#Map!S!t!a@PY@G@@@I@*MoreLabels#Map!S#key@@@J@@@K@@@M@@N@op@@n@@'of_list@@*MoreLabels#Map!S#key@@@Q@!a@ZY@R@@S@@@U*MoreLabels#Map!S!t@@@W@@X@CICn@@@@&to_seq@*MoreLabels#Map!S!t!a@dY@[@@@]&Stdlib#Seq!t@*MoreLabels#Map!S#key@@@^@#@@_@@@a@@b@(.(S@@@@*to_rev_seq@*MoreLabels#Map!S!t!a@nY@e@@@g&Stdlib#Seq!t@*MoreLabels#Map!S#key@@@h@#@@i@@@k@@l@@@@@+to_seq_from@*MoreLabels#Map!S#key@@@o@*MoreLabels#Map!S!t!a@zY@p@@@r&Stdlib#Seq!t@*MoreLabels#Map!S#key@@@s@#@@t@@@v@@w@@x@d7=e7n@@c@@'add_seq@&Stdlib#Seq!t@*MoreLabels#Map!S#key@@@{@!a@Y@|@@}@@@@*MoreLabels#Map!S!t@@@*MoreLabels#Map!S!t"@@@@@@@@C@@@@&of_seq@&Stdlib#Seq!t@*MoreLabels#Map!S#key@@@@!a@Y@@@@@@*MoreLabels#Map!S!t@@@@@@@@@@@@l+l-@@@ӱ$MakeZ@#Ord[  {\;@@@A!t@@@@@@@ v v@@@@ @A@ \;!a@`\@@A@AF#Map$Make+!t\@\@@@I@B@@@*+@@@@)@A@ % @@@@ @ @  ~@@@@ t r@ w@@@ {@@@@@@@@@@ Z@ W@ V U@@@ J H@(ݠ Q@@@@@@1 Z@@@@@@@@@@@@@ .@ +@ * )5@@@ @  @@@~  @@@}@@|@Q %@@@{U )@@@z@@y@@x@@w@ @ @ @T@@@v@ d @@@u@@t@@s@ @ @ @c@@@r@s @@@qw @@@p@@o@@n@ @ @  @x@@@m@  @@@l@  @@@k  @@@j@@i@@h@@g@ @@@f@ @@@e @@@d@@c@@b@@a@ @ |@ { z@@@@`@ o@ q i t@@@_@@^@@]@@\@ z@@@[@ @@@ZŠ @@@Y@@X@@W@@V@ M@ J@ I@Ϡ ?@@@U@@@T@@S@ 8@ 5@ 4@ݠ *@@@R@@@@Q@ 8@@P@@@O@@N@ @ @ @ @@@M@@@@L@ @@K@@J@@@@@@@I@@@@H@@@G@@@F@@E@@@@@@@D@@@@C@@@B@@A@@@@2@@@@@2@@@?@@@>@@@=@@<@@@@I@@@;@F@@@:@@@9@@8@@@@\y@@@7s@\@@@6@@@5@@@4@@3@i@f@e@h@@@2@xR@@@1S@@0@@/@L@I@H@w@@@.@5@@@-/9@@@,@@+@@*@.@+@*)@@@@)"@@@(@@'@@@@&@@@@%@@@$@@#@@"@@@@@@@!@@@@ @@@@@@@@@@@@@@@@@@@@@@@@@@@b@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@ @@@@ @@@ @@@ @@ @@@@@ @@@vtI@@@@@@@@"}@@@S@@@@@@@@c@`@_^\'@@@QO@II@@@@@@@;V@@@:QQ@@@@@@@8@5@43@1+@@@K6@@@O4@@@@@@@@@@@P@@@@@@@@@b@@@f@@@@@@@@@@@g@@@@@@@@@@@@}@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@}5@@@@@@@@@@@@@@@ՠ@@@@@@@@@@@[@X@W@@@@@РD@@@@ؠL@@@͠@5R@@@Π@X@@@@@@@@@@+@(@'@@@@z@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@@r@@@@@@@@7@@@@=@@@@@@@@@@@@@@@@B@@@@@@@@@@@@X@@@@@@@@@@@@@@]@@@@@@@@@@@@s@@@@@@@@@@@t@q@p@f@@@7@@@@@t@@@@@@@@V@S@R@K@@@@@G@@@@@K@@@@@@8@5@4@*@@@#Seq!t@@@@@;@@@@@@@@@@@̠ @@@+#Seq!t@@@@@@@@@@@@@@@@@@@@@@@K#Seq!t@@@@@@@@@@@@@@@@@@b#Seq!t@@@@@@@@@@@@@@@@@@@@@~@@@@#Seq!t@(@@@}@@@|@@@{9@@@z@@y@@@@@"oCGE@"m@@@@@"ree"s @"q@@@ӱ#Set]@+OrderedType_!t^;@@"A@@@@@"#@F"#@L@@@@"@A@'compare@*MoreLabels #Set+OrderedType!t@@@@*MoreLabels #Set+OrderedType!t@@@" @@@@@@@@"&{"&{@@"@@@@"!".sz@"@@!Sb#elt`;@@"A@@@@@"6"6@@@@"@A@!ta;@@"A@@@@@"9%"9+@@@@"@A@%empty*MoreLabels #Set!S!t@@@@"<LR"<L^@@"@@#add@*MoreLabels #Set!S#elt@@@@*MoreLabels#Set!S!t@@@*MoreLabels#Set!S!t@@@@@@@@#?|#?|@@#@@)singleton@*MoreLabels#Set!S#elt@@@*MoreLabels#Set!S!t@@@@@@#8E#9E@@#7@@&remove@*MoreLabels#Set!S#elt@@@@*MoreLabels#Set!S!t@@@*MoreLabels#Set!S!t@@@@@@@@#iH#jH4@@#h@@%union@*MoreLabels#Set!S!t@@@@*MoreLabels#Set!S!t@@@*MoreLabels#Set!S!t@@@@@@@@#NGM#NGc@@#@@%inter@*MoreLabels#Set!S!t@@@@*MoreLabels#Set!S!t@@@*MoreLabels#Set!S!t@@@@@@@@#Q}#Q}@@#@@(disjoint@*MoreLabels#Set!S!t@@@@*MoreLabels#Set!S!t@@@#@@@@@@@@#T#T@@#@@$diff@*MoreLabels#Set!S!t@@@@*MoreLabels#Set!S!t@@@*MoreLabels #Set!S!t@@@@@@@@$&X &$'X ;@@$%@@(cardinal@*MoreLabels!#Set!S!t@@@$"@@@@@@$B\$C\@@$A@@(elements@*MoreLabels##Set!S!t@@@"%*MoreLabels$#Set!S#elt@@@@@@@@@$ka"$la=@@$j@@'min_elt@*MoreLabels&#Set!S!t@@@*MoreLabels'#Set!S#elt@@@@@@$g*0$g*E@@$@@+min_elt_opt@*MoreLabels(#Set!S!t@@@$*MoreLabels)#Set!S#elt@@@@@@@@@$l$l@@$@@'max_elt@*MoreLabels*#Set!S!t@@@*MoreLabels+#Set!S#elt@@@@@@$r$r@@$@@+max_elt_opt@*MoreLabels,#Set!S!t@@@$*MoreLabels-#Set!S#elt@@@@@@@@@%v@F%v@f@@%@@&choose@*MoreLabels.#Set!S!t@@@*MoreLabels/#Set!S#elt@@@@@@%${%%{@@%#@@*choose_opt@*MoreLabels0#Set!S!t@@@%,*MoreLabels1#Set!S#elt@@@@@@@@@%L%M@@%K@@$find@*MoreLabels2#Set!S#elt@@@@*MoreLabels3#Set!S!t@@@*MoreLabels4#Set!S#elt@@@@@@@@%}%~ @@%|@@(find_opt@*MoreLabels5#Set!S#elt@@@@*MoreLabels6#Set!S!t@@@%*MoreLabels7#Set!S#elt@@@@@@@@@@@%%@@%@@*find_first!f@*MoreLabels8#Set!S#elt@@@%9@@@@@@*MoreLabels:#Set!S!t@@@*MoreLabels;#Set!S#elt@@@@@@@@%%@@%@@.find_first_opt!f@*MoreLabels<#Set!S#elt@@@%=@@@@@@*MoreLabels>#Set!S!t@@@& *MoreLabels?#Set!S#elt@@@@@@@@@@@&,&-@@&+@@)find_last!f@*MoreLabels@#Set!S#elt@@@&2A@@@@@@*MoreLabelsB#Set!S!t@@@*MoreLabelsC#Set!S#elt@@@@@@@@&f&g%@@&e@@-find_last_opt!f@*MoreLabelsD#Set!S#elt@@@&lE@@@@@@*MoreLabelsF#Set!S!t@@@&*MoreLabelsG#Set!S#elt@@@@@@ @@ @@ @& & F@@&@@$iter!f@*MoreLabelsH#Set!S#elt@@@ &aI@@@ @@ @*MoreLabelsJ#Set!S!t@@@ &tK@@@ @@ @@ @&ag&a@@&@@$fold!f@*MoreLabelsL#Set!S#elt@@@ @#acc@ b@ @@ @@ @*MoreLabelsM#Set!S!t@@@ $init@@ @@ @@ @' ag'a@@' @@#map!f@*MoreLabelsN#Set!S#elt@@@ *MoreLabelsO#Set!S#elt@@@ @@ @*MoreLabelsP#Set!S!t@@@ *MoreLabelsQ#Set!S!t@@@ @@ @@ @'Nek'Oe@@'M@@&filter!f@*MoreLabelsR#Set!S#elt@@@ 'TS@@@ @@ @*MoreLabelsT#Set!S!t@@@ *MoreLabelsU#Set!S!t@@@ @@ !@@ "@'z'z@@'@@*filter_map!f@*MoreLabelsV#Set!S#elt@@@ #'*MoreLabelsW#Set!S#elt@@@ $@@@ &@@ '@*MoreLabelsX#Set!S!t@@@ (*MoreLabelsY#Set!S!t@@@ )@@ *@@ +@''@@'@@)partition!f@*MoreLabelsZ#Set!S#elt@@@ ,'[@@@ -@@ .@*MoreLabels\#Set!S!t@@@ /@*MoreLabels]#Set!S!t@@@ 0@*MoreLabels^#Set!S!t@@@ 1@@ 2@@ 3@@ 4@()/()[@@(@@%split@*MoreLabels_#Set!S#elt@@@ 5@*MoreLabels`#Set!S!t@@@ 6@*MoreLabelsa#Set!S!t@@@ 7@(<b@@@ 8@*MoreLabelsc#Set!S!t@@@ 9@@ :@@ ;@@ <@(dU[(eU~@@(c@@(is_empty@*MoreLabelsd#Set!S!t@@@ =(fe@@@ >@@ ?@(17(1N@@(@@#mem@*MoreLabelsf#Set!S#elt@@@ @@*MoreLabelsg#Set!S!t@@@ A(h@@@ B@@ C@@ D@(ÁÇ(Áà@@(@@%equal@*MoreLabelsi#Set!S!t@@@ E@*MoreLabelsj#Set!S!t@@@ F(k@@@ G@@ H@@ I@((@@(@@'compare@*MoreLabelsl#Set!S!t@@@ J@*MoreLabelsm#Set!S!t@@@ K(n@@@ L@@ M@@ N@(zĀ(zĚ@@(@@&subset@*MoreLabelso#Set!S!t@@@ O@*MoreLabelsp#Set!S!t@@@ P)q@@@ Q@@ R@@ S@)( )) -@@)'@@'for_all!f@*MoreLabelsr#Set!S#elt@@@ T).s@@@ U@@ V@*MoreLabelst#Set!S!t@@@ W)Au@@@ X@@ Y@@ Z@)[ōœ)\ōż@@)Z@@&exists!f@*MoreLabelsv#Set!S#elt@@@ [)aw@@@ \@@ ]@*MoreLabelsx#Set!S!t@@@ ^)ty@@@ _@@ `@@ a@) !') !O@@)@@'to_list@*MoreLabelsz#Set!S!t@@@ b(E|*MoreLabels{#Set!S#elt@@@ c@@@ e@@ f@))@@)@@'of_list@(b~*MoreLabels}#Set!S#elt@@@ g@@@ i*MoreLabels#Set!S!t@@@ j@@ k@)JP)Jj@@)@@+to_seq_from@*MoreLabels#Set!S#elt@@@ l@*MoreLabels#Set!S!t@@@ m&Stdlib#Seq!t*MoreLabels#Set!S#elt@@@ n@@@ p@@ q@@ r@*OU*O|@@*@@&to_seq@*MoreLabels#Set!S!t@@@ s&Stdlib#Seq!t*MoreLabels#Set!S#elt@@@ t@@@ v@@ w@*J*K1@@*I@@*to_rev_seq@*MoreLabels#Set!S!t@@@ x&Stdlib#Seq!t*MoreLabels#Set!S#elt@@@ y@@@ {@@ |@*x"Ƀɉ*y"Ƀɨ@@*w@@'add_seq@&Stdlib#Seq!t*MoreLabels#Set!S#elt@@@ }@@@ @*MoreLabels#Set!S!t@@@ *MoreLabels#Set!S!t@@@ @@ @@ @*&*&"@@*@@&of_seq@&Stdlib#Seq!t*MoreLabels#Set!S#elt@@@ @@@ *MoreLabels#Set!S!t@@@ @@ @**tz**tʕ@@*@@@@*1*-@*@@ӱ$Makec@#Orddx6e;@@@A!t@@@&@@@@+1KT+1Kd@@@@+@A@=e;@@@A!8#Set$Make$!t@@@&@@@@+2en+2eˆ@@@@+@A@I@@@&@@@=@<@4@@@&@@@@&@@@&@@&@@&@!@@@@@@&@@@&@@&@ @@@@@@&@-@@@&0@@@&@@&@@&@@@@9@@@&@>@@@&A@@@&@@&@@&@@@@J@@@&@O@@@&R@@@&@@&@@&@@@@[@@@&@`@@@& @@@&@@&@@&@@@@m@@@&@r@@@&u@@@&@@&@@&@r@o@n@~@@@&!@@@&@@&@c@`@_@@@@&!.@@@&@@@&@@&@K@H@G@@@@&@@@&@@&@4@1@0@@@@&&@@@&@@@&@@&@@@@@@@&@@@&@@&@@@@@@@&@@@&@@@&@@&@@@@@@@&@@@&@@&@@@@@@@&Ƞ@@@&@@@&@@&@@@@@@@&@@@@&@@@&@@&@@&@@@@@@@&@@@@&@@@&@@@&@@&@@&@}@z@yx@@@@&!@@@&@@&@!@@@&@@@&@@&@@&@Z@W@VU@%@@@&!@@@&@@&@8@@@&@4@@@&@@@&@@&@@&@6@3@21@@@@@&!@@@&@@&@S@@@&L@@@&@@&@@&~@@@@W@@@&}!@@@&|@@&{@j@@@&zf@@@&y@@@&x@@&w@@&v@@@@r@@@&u"@@@&t@@&s@@@@&r"@@@&q@@&p@@&o@@@@@@@&n@@@&m@@&l@@@@&k@@&j@@&i@@&h@@@@@@@&g@@@&f@@&e@@@@&d@@@&c@@&b@@&a@@@@@@@&`"7@@@&_@@&^@@@@&]@@@&\@@&[@@&Z@e@b@a`@@@@&YU@@@&X@@@&W@@&V@@@@&U@@@&T@@&S@@&R@9@6@54@@@@&Q"h@@@&P@@&O@@@@&N@@@@&L@@@@&M@@&K@@&J@@&I@ @ @ @@@@&H@@@@&G@@@@&D@"@@@&E@$@@@&F@@&C@@&B@@&A@@@@-@@@&@"@@@&?@@&>@@@@0@@@&=@?@@@&<"@@@&;@@&:@@&9@@@@L@@@&8@Q@@@&7"@@@&6@@&5@@&4@@@@^@@@&3@c@@@&2#@@@&1@@&0@@&/@@@@p@@@&.@u@@@&-"@@@&,@@&+@@&*@t@q@po@z@@@&)"@@@&(@@&'@@@@&&#@@@&%@@&$@@&#@Y@V@UT@@@@&"#@@@&!@@& @@@@&#@@@&@@&@@&@>@;@:@@@@&#U@@@&@@@&@@&@&@#@"@#c@@@&@@@&@@@&@@&@@ @ @@@@&@@@@&$%#Seq!t@@@&@@@&@@&@@&@@@@@@@& $9#Seq!t@@@& @@@& @@& @@@@@@@& $M#Seq!t@@@&@@@&@@&@@@@$^#Seq!t@@@&@@@&@"@@@&%@@@&@@&@@&@@@@$w#Seq!t+@@@%@@@%9@@@%@@%@z@w@@@.\0D@.Z@@@@@._"".`6@.^@@@@38Extra labeled libraries.@ 8 This meta-module provides labelized versions of the 2MoreLabels.Hashtbl@@", .MoreLabels.Map@@( and .MoreLabels.Set@@) modules.@ / This module is intended to be used through /open MoreLabels3 which replaces @@", @@&, and @@ ! with their labeled counterparts.@4 For example: T open MoreLabels Hashtbl.iter ~f:(fun ~key ~data -> g key data) table @@@@@@@@@@@@A;../../stdlib/moreLabels.mli/;.@A?Hash tables and hash functions.@ Hash tables are hashed association tables, with in-place modification. Because most operations on a hash table modify their input, they're more commonly used in imperative code. The lookup of the value associated with a key (see 7MoreLabels.Hashtbl.findD@", ;MoreLabels.Hashtbl.find_optD@ I) is normally very fast, often faster than the equivalent lookup in N@@!.@3 The functors 7MoreLabels.Hashtbl.Make@@% and =MoreLabels.Hashtbl.MakeSeeded@@ can be used when performance or flexibility are key. The user provides custom equality and hash functions for the key type, and obtains a custom hash table type for this particular type of key.@& 'Warning@ a hash table is only as good as the hash function. A bad hash function will turn the table into a degenerate association list, with linear time lookup instead of constant time lookup.@6 The polymorphic 4MoreLabels.Hashtbl.tE@ d hash table is useful in simpler cases or in interactive environments. It uses the polymorphic 7MoreLabels.Hashtbl.hashD@ } function defined in the OCaml runtime (at the time of writing, it's SipHash), as well as the polymorphic equality #(=)!.@* See ;MoreLabels.Hashtbl.examples(Examples@5 the examples section@!.@7Unsynchronized accesses@@ Unsynchronized accesses to a hash table may lead to an invalid hash table state. Thus, concurrent accesses to a hash tables must be synchronized (for instance with a 'Mutex.t@@").@A@1Generic interface@@#A3 "The type of hash tables from type "'a) to type "'b!.@@@@@@@@@@@@/`O/]O@@A/Y@/G/E@@9MoreLabels.Hashtbl.create30Hashtbl.create n ` creates a new, empty hash table, with initial size greater or equal to the suggested size !n:. For best results, !n z should be on the order of the expected number of elements that will be in the table. The table grows as needed, so !n $ is just an initial guess. If !n X is very small or negative then it is disregarded and a small default size is used.@3 The optional '~random parameter (a boolean) controls whether the internal organization of the hash table is randomized at each execution of .Hashtbl.create & or deterministic over all executions.@ ( A hash table that is created with '~random( set to %false " uses a fixed hash function (D@ ) to distribute keys among buckets. As a consequence, collisions between keys happen deterministically. In Web-facing applications or other security-sensitive applications, the deterministic collision patterns can be exploited by a malicious user to create a denial-of-service attack: the attacker sends input crafted to create many collisions in the table, slowing the application down.@ ( A hash table that is created with '~random( set to $true $ uses the seeded hash function >MoreLabels.Hashtbl.seeded_hashD@ with a seed that is randomly chosen at hash table creation time. In effect, the hash function used is randomly selected among &2^{30}  different hash functions. All these hash functions have different collision patterns, rendering ineffective the denial-of-service attack described above. However, because of randomization, enumerating all elements of the hash table using 7MoreLabels.Hashtbl.foldD@) or 7MoreLabels.Hashtbl.iterD@ o is no longer deterministic: elements are enumerated in different orders at different runs of the program.@, If no '~random parameter is given, hash tables are created in non-random mode by default. This default can be changed either programmatically by calling Hashtbl.replace tbl ~key ~data ! replaces the current binding of #key) in #tbl1 by a binding of #key$ to $data&. If #key/ is unbound in #tbl4, a binding of #key$ to $data- is added to #tbl *. This is functionally equivalent to $D@( tbl key2 followed by ]D@- tbl key data!.@@@@@@@@@@@@/@/@//@//@@@@/33Hashtbl.iter ~f tbl) applies !f: to all bindings in table #tbl'. !f receives the key as first argument, and the associated value as second argument. Each binding is presented exactly once to !f!.@ 4 The order in which the bindings are passed to !f p is unspecified. However, if the table contains several bindings for the same key, they are passed to !f Y in reverse order of introduction, that is, the most recent binding is passed first.@ * If the hash table was created in non-randomized mode, the order in which the bindings are enumerated is reproducible between successive runs of the program, and even between minor versions of OCaml. For randomized hash tables, the order of enumeration is entirely random.@ J The behavior is not specified if the hash table is modified by !f6 during the iteration.@@@@@@@@@@@@/@//@/@@@@/à %MoreLabels.Hashtbl.filter_map_inplace3 !Hashtbl.filter_map_inplace ~f tbl) applies !f to all bindings in table #tbl : and update each binding depending on the result of !f&. If !f) returns $None 1, the binding is discarded. If it returns ,Some new_val 6, the binding is update to associate the key to 'new_val!.@: Other comments for kD@/ apply as well.@@@@$4.03@@@@@@@/@//@C/@@@@/ՠ39Hashtbl.fold ~f tbl ~init/ computes ?(f kN dN ... (f k1 d1 init)...)-, where )k1 ... kN ! are the keys of all bindings in #tbl+, and )d1 ... dN K are the associated values. Each binding is presented exactly once to !f!.@ 4 The order in which the bindings are passed to !f p is unspecified. However, if the table contains several bindings for the same key, they are passed to !f Y in reverse order of introduction, that is, the most recent binding is passed first.@ * If the hash table was created in non-randomized mode, the order in which the bindings are enumerated is reproducible between successive runs of the program, and even between minor versions of OCaml. For randomized hash tables, the order of enumeration is entirely random.@ J The behavior is not specified if the hash table is modified by !f6 during the iteration.@@@@@@@@@@@@0@00@/@/0@@@@/9MoreLabels.Hashtbl.length32Hashtbl.length tbl # returns the number of bindings in #tbl Q. It takes constant time. Multiple bindings are counted once each, so .Hashtbl.length; gives the number of times ,Hashtbl.iter? calls its first argument.@@@@@@@@@@@@0@0@@@@/頕30After a call to 3Hashtbl.randomize() ?, hash tables are created in randomized mode by default: oD@ 2 returns randomized hash tables, unless the -~random:false S optional parameter is given. The same effect can be achieved by setting the !R8 parameter in the -OCAMLRUNPARAM6 environment variable.@ It is recommended that applications or Web frameworks that need to protect themselves against the denial-of-service attack described in D@& call 3Hashtbl.randomize() = at initialization time before any domains are created.@6 Note that once 3Hashtbl.randomize() W was called, there is no way to revert to the non-randomized default behavior of D@ Z. This is intentional. Non-randomized hash tables can still be created using to produce a hash table for the current version of the @@. module.@@@@$4.12@@@@@@@0v@0v0u@0m@@@@0K#=MoreLabels.Hashtbl.statistics3@@@@$4.00@@@@@@@@0I@@0H3 MNumber of bindings present in the table. Same value as returned by D@!.@@@@@@@@@@@@0J@@0I3?Number of buckets in the table.@@@@@@@@@@@@0E@@0D3 &Maximal number of bindings per bucket.@@@@@@@@@@@@0@@@0?3 'Histogram of bucket sizes. This array %histo6 has length 5max_bucket_length + 1:. The value of )histo.(i) ( is the number of buckets whose size is !i!.@@@@@@@@@@@@@A0N@0F0E@@8MoreLabels.Hashtbl.stats31Hashtbl.stats tbl $ returns statistics about the table #tbl [: number of buckets, size of the biggest bucket, distribution of buckets by size.@@@@$4.00@@@@@@@0S@0T@@@@04A@9Hash tables and Sequences@@9MoreLabels.Hashtbl.to_seq3 Iterate on the whole table. The order in which the bindings appear in the sequence is unspecified. However, if the table contains several bindings for the same key, they appear in reversed order of introduction, that is, the most recent binding appears first.@ ^ The behavior is not specified if the hash table is modified during the iteration.@@@@$4.07@@@@@@@0B@0C@@@@0>MoreLabels.Hashtbl.to_seq_keys3(Same as 6Seq.map fst (to_seq m)@@@@$4.07@@@@@@@0"@0#@@@@0 MoreLabels.Hashtbl.to_seq_values3(Same as 6Seq.map snd (to_seq m)@@@@$4.07@@@@@@@0 @,0 @@@@/:MoreLabels.Hashtbl.add_seq3 +Add the given bindings to the table, using D@@@@@$4.07@@@@@@@/@@/@C/@@@@/̠>MoreLabels.Hashtbl.replace_seq3 +Add the given bindings to the table, using ̐D@@@@@$4.07@@@@@@@/@W/@Z/@@@@/9MoreLabels.Hashtbl.of_seq3 yBuild a table from the given bindings. The bindings are added in the same order they appear in the sequence, using  D@ l, which means that if two pairs have the same key, only the latest one will appear in the table.@@@@$4.07@@@@@@@/@q/@@@@/A@4Functorial interface@@ The functorial interface allows the use of specific comparison and hash functions, either for performance/security concerns, or because keys are not hashable/comparable with the polymorphic builtins.@ R For instance, one might want to specialize a table for integer keys:  module IntHash = struct type t = int let equal i j = i=j let hash i = i land max_int end module IntHashtbl = Hashtbl.Make(IntHash) let h = IntHashtbl.create 17 in IntHashtbl.add h 12 "hello" @ ! This creates a new module *IntHashtbl2, with a new type 5'a IntHashtbl.t0 of tables from #int$ to "'a3. In this example, !h0 contains &string7 values so its type is 3string IntHashtbl.t!.@> Note that the new type /'a IntHashtbl.t ' is not compatible with the type 1('a,'b) Hashtbl.t . of the generic interface. For example, 0Hashtbl.length h * would not type-check, you must use 1IntHashtbl.length!.@=MoreLabels.Hashtbl.HashedType3 #The input signature of the functor @@!.@@@@@@@@@@@@/A)#?MoreLabels.Hashtbl.HashedType.t3?The type of the hashtable keys.@@@@@@@@@@@@@@A@@//@@ #MoreLabels.Hashtbl.HashedType.equal3 ,The equality predicate used to compare keys.@@@@@@@@@@@@/@/@/@@@@/ࠕ "MoreLabels.Hashtbl.HashedType.hash3 `A hashing function on keys. It must be such that if two keys are equal according to %equal B, then they have identical hash values as computed by $hash ". Examples: suitable (%equal", $hash 3) pairs for arbitrary key types include) (#(=)", -D@ ]) for comparing objects by structure (provided objects do not contain floats)@) (<(fun x y -> compare x y = 0)", =D@ R) for comparing objects by structure and handling *Stdlib.nan@@* correctly@) ($(==)", SD@ b) for comparing objects by physical equality (e.g. for mutable or cyclic objects).@@@@@@@@@@@@@@01@_02@@@@0#@@0!0 @4MoreLabels.Hashtbl.S3 $The output signature of the functor @@!.@@@@@@@@@@@@0)A#8MoreLabels.Hashtbl.S.key@@@A@@0+0*@@#6MoreLabels.Hashtbl.S.t@0(O@@A@@0$0#@@;MoreLabels.Hashtbl.S.create@0 @0!@@@@0 :MoreLabels.Hashtbl.S.clear@0@0@@@@/:MoreLabels.Hashtbl.S.reset3@@@@$4.00@@@@@@@/@/@@@@/۠9MoreLabels.Hashtbl.S.copy@/@/@@@@/8MoreLabels.Hashtbl.S.add@/@/@//@//@@@@/;MoreLabels.Hashtbl.S.remove@/@/@/{@@@@/l9MoreLabels.Hashtbl.S.find@/g@/h@/V@@@@/L=MoreLabels.Hashtbl.S.find_opt3@@@@$4.05@@@@@@@/K@/L@/:@@@@/+=MoreLabels.Hashtbl.S.find_all@/&@/'@/@@@@/ for any value of $seed9. A suitable choice for +seeded_hash= is the function D@' below.@@@@@@@@@@@@+>@M+?@P+;@@@@+,@@+*+)@:MoreLabels.Hashtbl.SeededS3 $The output signature of the functor y@@!.@@@@$4.00@@@@@@@+4A#>MoreLabels.Hashtbl.SeededS.key@@@A@@+6+5@@#MoreLabels.Hashtbl.SeededS.add@*@*@**@**@@@@* !MoreLabels.Hashtbl.SeededS.remove@*@*@*x@@@@*i?MoreLabels.Hashtbl.SeededS.find@*d@*e@*S@@@@*I #MoreLabels.Hashtbl.SeededS.find_opt3@@@@$4.05@@@@@@@*H@*I@*7@@@@*( #MoreLabels.Hashtbl.SeededS.find_all@*#@*$@*@@@@* "MoreLabels.Hashtbl.SeededS.replace@)@)@))@))@@@@)ڠ>MoreLabels.Hashtbl.SeededS.mem@)@)@)@@@@)?MoreLabels.Hashtbl.SeededS.iter@)@))@ )@@@@) -MoreLabels.Hashtbl.SeededS.filter_map_inplace3@@@@$4.03@@@@@@@)@))@)a@@@@)Q?MoreLabels.Hashtbl.SeededS.fold@)L@)L)K@%)*@))5@@@@) !MoreLabels.Hashtbl.SeededS.length@)@1)@@@@) MoreLabels.Hashtbl.SeededS.stats@(@:)@@@@(堕 !MoreLabels.Hashtbl.SeededS.to_seq3@@@@$4.07@@@@@@@(@G(@@@@( &MoreLabels.Hashtbl.SeededS.to_seq_keys3@@@@$4.07@@@@@@@(@T(@@@@( (MoreLabels.Hashtbl.SeededS.to_seq_values3@@@@$4.07@@@@@@@(@a(@@@@(w "MoreLabels.Hashtbl.SeededS.add_seq3@@@@$4.07@@@@@@@(v@n(w@q(e@@@@(E &MoreLabels.Hashtbl.SeededS.replace_seq3@@@@$4.07@@@@@@@(D@~(E@(3@@@@( !MoreLabels.Hashtbl.SeededS.of_seq3@@@@$4.07@@@@@@@(@(@@@@'@@''@/ 'ސ3 QFunctor building an implementation of the hashtable structure. The functor 2Hashtbl.MakeSeeded - returns a structure containing a type #key4 of keys and a type $'a t / of hash tables associating data of type "'a1 to keys of type #key . The operations perform similarly to those of the generic interface, but use the seeded hashing and equality functions specified in the functor argument !H 5 instead of generic equality and hashing. The &create 6 operation of the result structure supports the '~random @ optional parameter and returns randomized hash tables if ,~random:true 9 is passed or if randomization is globally on (see D@").@@@@$4.00@@@@@@@A "( *MoreLabelsu'Hashtbl0SeededHashedType0SeededHashedType@ H with type key = H.t and type 'a t = 'a Hashtbl.MakeSeeded(H).t@&-(@@@@@A@>The polymorphic hash functions@@ 3.Hashtbl.hash x _ associates a nonnegative integer to any value of any type. It is guaranteed that if %x = y$ or 6Stdlib.compare x y = 0', then /hash x = hash y1. Moreover, $hash . always terminates, even on cyclic structures.@@@@@@@@@@@@&Q@ &R@@@@&I k3-A variant of  %D@ 7 that is further parameterized by an integer seed.@@@@$4.00@@@@@@@&Q@ 4&R@ 7&N@@@@&E=MoreLabels.Hashtbl.hash_param3 %Hashtbl.hash_param meaningful total x; computes a hash value for !x ', with the same properties as for $hash (. The two extra integer parameters *meaningful% and %total ~ give more precise control over hashing. Hashing performs a breadth-first, left-to-right traversal of the structure !x1, stopping after *meaningful , meaningful nodes were encountered, or %total 6 nodes (meaningful or not) were encountered. If %total as specified by the user exceeds a certain value, currently 256, then it is capped to that value. Meaningful nodes are: integers; floating-point numbers; strings; characters; booleans; and constant constructors. Larger values of *meaningful% and %total means that more nodes are taken into account to compute the final hash value, and therefore collisions are less likely to happen. However, hashing takes longer. The parameters *meaningful% and %total P govern the tradeoff between accuracy and speed. As default choices,  D@% and  ސD@+ take /meaningful = 10% and +total = 100!.@@@@@@@@@@@@&@ &@ &@ &@@@@& $MoreLabels.Hashtbl.seeded_hash_param3-A variant of D@ E that is further parameterized by an integer seed. Usage: 1Hashtbl.seeded_hash_param meaningful total seed x!.@@@@$4.00@@@@@@@&@ &@ &@ &@ &@@@@&A(examples @@% B@-Basic Example@@% | (* 0...99 *) let seq = Seq.ints 0 |> Seq.take 100 (* build from Seq.t *) # let tbl = seq |> Seq.map (fun x -> x, string_of_int x) |> Hashtbl.of_seq val tbl : (int, string) Hashtbl.t = # Hashtbl.length tbl - : int = 100 # Hashtbl.find_opt tbl 32 - : string option = Some "32" # Hashtbl.find_opt tbl 166 - : string option = None # Hashtbl.replace tbl 166 "one six six" - : unit = () # Hashtbl.find_opt tbl 166 - : string option = Some "one six six" # Hashtbl.length tbl - : int = 101 @% B@1Counting Elements@@ + Given a sequence of elements (here, a %Seq.t@@ ), we want to count how many times each distinct element occurs in the sequence. A simple way to do this, assuming the elements are comparable and hashable, is to use a hash table that maps elements to their number of occurrences.@ X Here we illustrate that principle using a sequence of (ascii) characters (type $char7). We use a custom (Char_tbl1 specialized for $char!.@%  # module Char_tbl = Hashtbl.Make(struct type t = char let equal = Char.equal let hash = Hashtbl.hash end) (* count distinct occurrences of chars in [seq] *) # let count_chars (seq : char Seq.t) : _ list = let counts = Char_tbl.create 16 in Seq.iter (fun c -> let count_c = Char_tbl.find_opt counts c |> Option.value ~default:0 in Char_tbl.replace counts c (count_c + 1)) seq; (* turn into a list *) Char_tbl.fold (fun c n l -> (c,n) :: l) counts [] |> List.sort (fun (c1,_)(c2,_) -> Char.compare c1 c2) val count_chars : Char_tbl.key Seq.t -> (Char.t * int) list = (* basic seq from a string *) # let seq = String.to_seq "hello world, and all the camels in it!" val seq : char Seq.t = # count_chars seq - : (Char.t * int) list = [(' ', 7); ('!', 1); (',', 1); ('a', 3); ('c', 1); ('d', 2); ('e', 3); ('h', 2); ('i', 2); ('l', 6); ('m', 1); ('n', 2); ('o', 2); ('r', 1); ('s', 1); ('t', 2); ('w', 1)] (* "abcabcabc..." *) # let seq2 = Seq.cycle (String.to_seq "abc") |> Seq.take 31 val seq2 : char Seq.t = # String.of_seq seq2 - : String.t = "abcabcabcabcabcabcabcabcabcabca" # count_chars seq2 - : (Char.t * int) list = [('a', 11); ('b', 10); ('c', 10)] @@@&&@@@@@/ &@A l &Association tables over ordered types.@ u This module implements applicative association tables, also known as finite maps or dictionaries, given a total ordering function over the keys. All operations over maps are purely applicative (no side-effects). The implementation uses balanced binary trees, and therefore searching and insertion take time logarithmic in the size of the map.@9 For instance: k module IntPairs = struct type t = int * int let compare (x0,y0) (x1,y1) = match Stdlib.compare x0 x1 with 0 -> Stdlib.compare y0 y1 | c -> c end module PairsMap = Map.Make(IntPairs) let m = PairsMap.(empty |> add (0,1) "hello" |> add (1,0) "world") @ This creates a new module (PairsMap2, with a new type -'a PairsMap.t3 of maps from )int * int$ to "'a3. In this example, !m* contains &string< values so its type is 1string PairsMap.t!.@:MoreLabels.Map.OrderedType3?Input signature of the functor 3MoreLabels.Map.Make@@!.@@@@@@@@@@@@'A # operation, we have @find_opt x (merge f m1 m2) = f x (find_opt x m1) (find_opt x m2)7 for any key !x0, provided that 4f x None None = None!.@@@@$3.12@@@@@@@'@''@ '@ '@@@@'6MoreLabels.Map.S.union3.union ~f m1 m2 A computes a map whose keys are a subset of the keys of "m1( and of "m2 N. When the same binding is defined in both arguments, the function !f > is used to combine them. This is a special case of %merge": -union f m1 m2< is equivalent to .merge f' m1 m2', where8f' _key None None = None@>f' _key (Some v) None = Some v@>f' _key None (Some v) = Some v@ (f' key (Some v1) (Some v2) = f key v1 v2@@@@@@$4.03@@@@@@@'@''@ @'@ C'@@@@'9MoreLabels.Map.S.cardinal3 'Return the number of bindings of a map.@@@@$3.12@@@@@@@'@ T'@@@@'rA(bindings(Bindings@@9MoreLabels.Map.S.bindings3 Return the list of all bindings of the given map. The returned list is sorted in increasing order of keys with respect to the ordering +Ord.compare(, where #Ord $ is the argument given to @@!.@@@@$3.12@@@@@@@'@ '@@@@'h returns the current value of !x$ in !m6, or raises )Not_found3 if no binding for !x( exists.@@@@@@@@@@@@&@I&@L&@@@@&٠9MoreLabels.Map.S.find_opt3,find_opt x m) returns &Some v9 if the current value of !x. in !m$ is !v%, or $None3 if no binding for !x( exists.@@@@$4.05@@@@@@@'@'@&@@@@&㠕;MoreLabels.Map.S.find_first3/find_first ~f m(, where !f J is a monotonically increasing function, returns the binding of !m5 with the lowest key !k+ such that #f k6, or raises )Not_found7 if no such key exists.@8 For example, ,find_first (fun k -> Ord.compare k x >= 0) m ) will return the first binding $k, v$ of !m' where 4Ord.compare k x >= 09 (intuitively: &k >= x,), or raise )Not_found$ if !x * is greater than any element of !m!.@@@@$4.05@@@@@@@';@';':@'(@@@@'?MoreLabels.Map.S.find_first_opt33find_first_opt ~f m(, where !f _ is a monotonically increasing function, returns an option containing the binding of !m? with the lowest key !k+ such that #f k%, or $None7 if no such key exists.@@@@$4.05@@@@@@@')@')'(@%'@@@@&:MoreLabels.Map.S.find_last3.find_last ~f m(, where !f J is a monotonically decreasing function, returns the binding of !m6 with the highest key !k+ such that #f k6, or raises )Not_found7 if no such key exists.@@@@$4.05@@@@@@@'@''@Z&@@@@&ܠ>MoreLabels.Map.S.find_last_opt32find_last_opt ~f m(, where !f _ is a monotonically decreasing function, returns an option containing the binding of !m with the highest key !k+ such that #f k%, or $None ! if no such key exists.@@@@$4.05@@@@@@@'@'&@&@@@@&ŠA*traversing*Traversing@@5MoreLabels.Map.S.iter3)iter ~f m) applies !f8 to all bindings in map !m,. !f x receives the key as first argument, and the associated value as second argument. The bindings are passed to !f V in increasing order with respect to the ordering over the type of the keys.@@@@@@@@@@@@&@&&@&@@@@&5MoreLabels.Map.S.fold3/fold ~f m ~init* computes ?(f kN dN ... (f k1 d1 init)...)2, where )k1 ... kN ! are the keys of all bindings in !m & (in increasing order), and )d1 ... dN9 are the associated data.@@@@@@@@@@@@&@&&@&@&&@@@@&A,transforming,Transforming@@4MoreLabels.Map.S.map3(map ~f m # returns a map with same domain as !m ', where the associated value !a4 of all bindings of !m A has been replaced by the result of the application of !f$ to !a '. The bindings are passed to !f V in increasing order with respect to the ordering over the type of the keys.@@@@@@@@@@@@&@&&@7&@@@@&5MoreLabels.Map.S.mapi3(Same as BD@ u, but the function receives as arguments both the key and the associated value for each binding of the map.@@@@@@@@@@@@&@&&@O&@@@@&7MoreLabels.Map.S.filter3+filter ~f m * returns the map with all the bindings in !m " that satisfy predicate !p6. If every binding in !m+ satisfies !f,, !m Y is returned unchanged (the result of the function is then physically equal to !m!)@@@@$3.12$4.03 "Physical equality was not ensured.@@@@@@@@&@&&@&@@@@&;MoreLabels.Map.S.filter_map3/filter_map ~f m6 applies the function !f? to every binding of !m @, and builds a map from the results. For each binding &(k, v)2 in the input map:#if %f k v$ is $None& then !k6 is not in the result,@#if %f k v$ is 'Some v'2 then the binding '(k, v') " is in the output map.@@ X For example, the following function on maps whose values are lists u filter_map (fun _k li -> match li with [] -> None | _::tl -> Some tl) m ! drops all bindings of !m d whose value is an empty list, and pops the first element of each value that is non-empty.@@@@$4.11@@@@@@@&@&&@&@@@@&:MoreLabels.Map.S.partition3.partition ~f m8 returns a pair of maps ((m1, m2)2, where "m1> contains all the bindings of !m & that satisfy the predicate !f&, and "m2 / is the map with all the bindings of !m5 that do not satisfy !f!.@@@@$3.12@@@@@@@&@&&@7&@@@@&6MoreLabels.Map.S.split3)split x m2 returns a triple ,(l, data, r)4, where !l % is the map with all the bindings of !m + whose key is strictly less than !x.; !r % is the map with all the bindings of !m . whose key is strictly greater than !x.; $data$ is $None$ if !m9 contains no binding for !x1, or &Some v$ if !m' binds !v$ to !x!.@@@@$3.12@@@@@@@&@&@&@@@@&A*predicates:Predicates and comparisons@@9MoreLabels.Map.S.is_empty3 #Test whether a map is empty or not.@@@@@@@@@@@@&@&@@@@&4MoreLabels.Map.S.mem3'mem x m) returns $true$ if !m8 contains a binding for !x0, and %false+ otherwise.@@@@@@@@@@@@&@&@&@@@@&6MoreLabels.Map.S.equal30equal ~cmp m1 m28 tests whether the maps "m1% and "m2 a are equal, that is, contain equal keys and associate them with equal data. #cmp W is the equality predicate used to compare the data associated with the keys.@@@@@@@@@@@@&@&&@&@&@@@@&8MoreLabels.Map.S.compare3 Total ordering between maps. The first argument is a total ordering used to compare data associated with equal keys in the two maps.@@@@@@@@@@@@&@&&@)&v@,&j@@@@&Z8MoreLabels.Map.S.for_all3,for_all ~f m G checks if all the bindings of the map satisfy the predicate !f!.@@@@$3.12@@@@@@@&f@&f&e@I&K@@@@&;7MoreLabels.Map.S.exists3+exists ~f m M checks if at least one binding of the map satisfies the predicate !f!.@@@@$3.12@@@@@@@&G@&G&F@f&,@@@@&A*converting*Converting@@8MoreLabels.Map.S.to_list3)to_list m$ is D@" m!.@@@@#5.1@@@@@@@&4@&5@@@@& 8MoreLabels.Map.S.of_list3*of_list bs6 adds the bindings of "bs G to the empty map, in list order (if a key is bound twice in "bs $ the last one takes over).@@@@#5.1@@@@@@@&@&@@@@%7MoreLabels.Map.S.to_seq3 4Iterate on the whole map, in ascending order of keys@@@@$4.07@@@@@@@%@%@@@@%̠;MoreLabels.Map.S.to_rev_seq3 5Iterate on the whole map, in descending order of keys@@@@$4.12@@@@@@@%@%@@@@% Stdlib.compare y0 y1 | c -> c end module PairsSet = Set.Make(IntPairs) let m = PairsSet.(empty |> add (2,3) |> add (5,7) |> add (11,13)) @ This creates a new module (PairsSet2, with a new type *PairsSet.t1 of sets of )int * int!.@:MoreLabels.Set.OrderedType3?Input signature of the functor 0@@!.@@@@@@@@@@@@ A͐#!=@@6MoreLabels.Set.S.empty3.The empty set.@@@@@@@@@@@@!@@@@@!64MoreLabels.Set.S.add3'add x s * returns a set containing all elements of !s1, plus !x%. If !x0 was already in !s", !s Y is returned unchanged (the result of the function is then physically equal to !s").@@@@@$4.03 "Physical equality was not ensured.@@@@@@@@!d@g!e@j!Z@@@@!D:MoreLabels.Set.S.singleton3+singleton x - returns the one-element set containing only !x!.@@@@@@@@@@@@!N@!O@@@@!97MoreLabels.Set.S.remove3*remove x s * returns a set containing all elements of !s3, except !x%. If !x, was not in !s", !s Y is returned unchanged (the result of the function is then physically equal to !s").@@@@@$4.03 "Physical equality was not ensured.@@@@@@@@!g@!h@!]@@@@!G6MoreLabels.Set.S.union3*Set union.@@@@@@@@@@@@!H@!I@!>@@@@!(6MoreLabels.Set.S.inter31Set intersection.@@@@@@@@@@@@!)@!*@!@@@@! 9MoreLabels.Set.S.disjoint3>Test if two sets are disjoint.@@@@$4.08@@@@@@@! @! @!@@@@ 5MoreLabels.Set.S.diff30Set difference: *diff s1 s2: contains the elements of "s1; that are not in "s2!.@@@@@@@@@@@@!@!@ @@@@ 栕9MoreLabels.Set.S.cardinal3 'Return the number of elements of a set.@@@@@@@@@@@@ @, @@@@ ٠A(elements(Elements@@9MoreLabels.Set.S.elements3 Return the list of all elements of the given set. The returned list is sorted in increasing order with respect to the ordering +Ord.compare(, where #Ord $ is the argument given to @@!.@@@@@@@@@@@@ @V @@@@ ڠ8MoreLabels.Set.S.min_elt3 LReturn the smallest element of the given set (with respect to the +Ord.compare? ordering), or raise )Not_found5 if the set is empty.@@@@@@@@@@@@ @q @@@@ Ҡ Ord.compare e x >= 0) s ) will return the first element !e$ of !s' where 4Ord.compare e x >= 09 (intuitively: &e >= x,), or raise )Not_found$ if !x * is greater than any element of !s!.@@@@$4.05@@@@@@@ @  @ @@@@ ?MoreLabels.Set.S.find_first_opt33find_first_opt ~f s(, where !f c is a monotonically increasing function, returns an option containing the lowest element !e$ of !s5 such that #f e%, or $None; if no such element exists.@@@@$4.05@@@@@@@ @  @ @@@@ :MoreLabels.Set.S.find_last3.find_last ~f s(, where !f O is a monotonically decreasing function, returns the highest element !e$ of !s+ such that #f e6, or raises )Not_found; if no such element exists.@@@@$4.05@@@@@@@ @  @  @@@@ >MoreLabels.Set.S.find_last_opt32find_last_opt ~f s(, where !f d is a monotonically decreasing function, returns an option containing the highest element !e$ of !s5 such that #f e%, or $None; if no such element exists.@@@@$4.05@@@@@@@ @  @U @@@@ A*traversing*Traversing@@5MoreLabels.Set.S.iter3)iter ~f s) applies !f< in turn to all elements of !s<. The elements of !s2 are presented to !f Z in increasing order with respect to the ordering over the type of the elements.@@@@@@@@@@@@ @  @ @@@@ 5MoreLabels.Set.S.fold3.fold ~f s init* computes (f xN ... (f x2 (f x1 init))...)2, where )x1 ... xN5 are the elements of !s6, in increasing order.@@@@@@@@@@@@ @  @ @  @@@@ A,transforming,Transforming@@4MoreLabels.Set.S.map3(map ~f s? is the set whose elements are $f a0!,$f a1$... .f aN(, where "a0!,"a1#..."aN5 are the elements of !s!.@ & The elements are passed to !f Z in increasing order with respect to the ordering over the type of the elements.@< If no element of !s/ is changed by !f", !s 5 is returned unchanged. (If each output of !f U is physically equal to its input, the returned set is physically equal to !s".)@@@@$4.04@@@@@@@ @  @+ @@@@ ̠7MoreLabels.Set.S.filter3+filter ~f s $ returns the set of all elements in !s " that satisfy predicate !f%. If !f< satisfies every element in !s,, !s Y is returned unchanged (the result of the function is then physically equal to !s").@@@@@$4.03 "Physical equality was not ensured.@@@@@@@@ @  @j @@@@ Ѡ;MoreLabels.Set.S.filter_map3/filter_map ~f s8 returns the set of all !v5 such that ,f x = Some v2 for some element !x$ of !s!.@ " For example, Bfilter_map (fun n -> if n mod 2 = 0 then Some (n / 2) else None) s 8 is the set of halves of the even elements of !s!.@< If no element of !s: is changed or dropped by !f/ (if ,f x = Some x2 for each element !x2), then !s Y is returned unchanged: the result of the function is then physically equal to !s!.@@@@$4.11@@@@@@@!'@!'!&@!@@@@ :MoreLabels.Set.S.partition3.partition ~f s8 returns a pair of sets ((s1, s2)2, where "s1 # is the set of all the elements of !s & that satisfy the predicate !f&, and "s2 - is the set of all the elements of !s5 that do not satisfy !f!.@@@@@@@@@@@@! @! !@! @@@@ 堕6MoreLabels.Set.S.split3)split x s2 returns a triple /(l, present, r)2, where !l; is the set of elements of !s ' that are strictly less than !x,; !r; is the set of elements of !s * that are strictly greater than !x,; 'present$ is %false$ if !s> contains no element equal to !x/, or $true$ if !s> contains an element equal to !x!.@@@@@@@@@@@@!=@v!>@y!3@@@@!A*predicates:Predicates and comparisons@@9MoreLabels.Set.S.is_empty3 #Test whether a set is empty or not.@@@@@@@@@@@@!@!@@@@!4MoreLabels.Set.S.mem3'mem x s/ tests whether !x4 belongs to the set !s!.@@@@@@@@@@@@!@!@!@@@@ 6MoreLabels.Set.S.equal3+equal s1 s28 tests whether the sets "s1% and "s2 6 are equal, that is, contain equal elements.@@@@@@@@@@@@!@!@ @@@@ 8MoreLabels.Set.S.compare3 cTotal ordering between sets. Can be used as the ordering function for doing sets of sets.@@@@@@@@@@@@ @ @ @@@@ ֠7MoreLabels.Set.S.subset3,subset s1 s27 tests whether the set "s1 " is a subset of the set "s2!.@@@@@@@@@@@@ @ @ @@@@ ͠8MoreLabels.Set.S.for_all3,for_all ~f s C checks if all elements of the set satisfy the predicate !f!.@@@@@@@@@@@@ @  @! @@@@ 7MoreLabels.Set.S.exists3+exists ~f s M checks if at least one element of the set satisfies the predicate !f!.@@@@@@@@@@@@ @  @< @@@@ A*converting*Converting@@8MoreLabels.Set.S.to_list3)to_list s$ is D@" s!.@@@@#5.1@@@@@@@ @b @@@@ 8MoreLabels.Set.S.of_list3)of_list l ^ creates a set from a list of elements. This is usually more efficient than folding #add Q over the list, except perhaps for lists with many duplicated elements.@@@@$4.02@@@@@@@ @| @@@@