yQ`J-55.5.0+dev0-2025-04-28/&String!tA;@@@A&string@@@@@@@7../../stdlib/string.mliK  K  @@@@&String@@A@$make@#int@@@@$char@@@!@@@@@@@@ N ; ;!N ; [@@A@@$init@@@@@@'@@@$@@@@@D@@@@@@@@CTDT,@@BB@@%emptyR@@@@Q[R[@@PC@@&length@b@@@T@@@@@.%string_lengthAA @@@kaFFlaFx@@jD@@#get@|@@@@p@@@m@@@@@@@0%string_safe_getBA!@@@@dd@@E@@(of_bytes@%bytes@@@@@@@@@jj@@F@@(to_bytes@@@@@@@@@@qq:@@G@@$blit@@@@@@@@@9@@@@@@@@@@@$unit@@@@@@@@@@@@@@xy@@H@@&concat@@@@@$listϠ@@@@@@ @@@@@@@@  @@ I@@#cat@@@@@$@@@)@@@@@@@@()@@'J@@%equal@&String!t@@@@&String!t@@@$bool@@@@@@@@KL@@JK@@'compare@&String!t@@@@&String!t@@@[@@@@@@@@m--n-H@@lL@@+starts_with&prefix@@@@@@@A@@@@@@@@C@@M@@)ends_with &suffix@@@@@@@_@@@@@@@@ @@N@@-contains_from!@@@@@@@@@@@@@@@@@@@@@@ppp@@O@@.rcontains_from"@@@@@@@@@@@@@@@@@@@@@@TTT@@P@@(contains#@@@@@@@@@@@@@@@@ NN Ns@@ Q@@#sub$@@@@@@@@@@@@/@@@@@@@@@@./@@-R@@-split_on_char%@$@@@@F@@@JP@@@ @@@ @@ @@ @PQ#@@OS@@#map&@@H@@@M@@@@@@o@@@t@@@@@@@@st@@rT@@$mapi'@@s@@@@r@@@w@@@@@@@@@@@@@@@@@@@///c@@U@@)fold_left(@@#acc@'B@@@@@ @@ @@!@@@@@"@@#@@$@@%@@@V@@*fold_right)@@@@@(@#acc@1B@)@@*@@+@@@@,@@@-@@.@@/@@@W@@'for_all*@@@@@2@@@3@@4@@@@5@@@6@@7@@8@ t t t @@X@@&exists+@@@@@9@@@:@@;@%@@@<@@@=@@>@@?@)!!*!!1@@(Y@@$trim,@:@@@@? @@@A@@B@>!!?!!@@=Z@@'escaped-@O @@@CT @@@D@@E@S"f"fT"f"@@R[@@/uppercase_ascii.@d @@@Fi @@@G@@H@h$$i$$@@g\@@/lowercase_ascii/@y@@@I~@@@J@@K@} %c%c~ %c%@@|]@@0capitalize_ascii0@@@@L@@@M@@N@&/&/&/&V@@^@@2uncapitalize_ascii1@@@@O@@@P@@Q@&&&'@@_@@$iter2@@@@@R@@@S@@T@@@@U@@@V@@W@@X@!''!'( @@`@@%iteri3@@@@@Y@@@@Z@@@[@@\@@]@@@@^ @@@_@@`@@a@%((%((@@a@@*index_from4@@@@b@@@@c@@@@d @@@e@@f@@g@@h@-)n)n-)n)@@b@@.index_from_opt5@(!@@@i@"@@@j@#@@@k&optionL.$@@@l@@@n@@o@@p@@q@A5**B5**@@@c@@+rindex_from6@R%@@@r@F&@@@s@E'@@@tR(@@@u@@v@@w@@x@d<++e<++@@cd@@/rindex_from_opt7@u)@@@y@i*@@@z@h+@@@{My,@@@|@@@~@@@@@@@C,,C,,@@e@@%index8@-@@@@.@@@/@@@@@@@@J--J--@@f@@)index_opt9@0@@@@1@@@2@@@@@@@@@@@M..M..=@@g@@&rindex:@3@@@@4@@@5@@@@@@@@R..R..@@h@@*rindex_opt;@6@@@@7@@@Ǡ8@@@@@@@@@@@U..U./ @@i@@&to_seq{@&String9!t@@@&Stdlib;#Seq!t:@@@ @@@ @@ @)\//*\//@@(j@@'to_seqi|@&String@@@ @@ @@@ @@ @Wb0(0(Xb0(0M@@Vk@@&of_seq}@&StdlibA#Seq!tW@@@@ @@@ &StringB!t@@@ @@ @zg00{g00@@yl@@/get_utf_8_uchar@&StringC!t@@@ @D@@@ &StdlibE%Uchar*utf_decode@@@ r@@ s@@ t@r1t1tr1t1@@m@@.is_valid_utf_8@&StringF!t@@@ ulG@@@ v@@ w@v11v12@@n@@2get_utf_16be_uchar@&StringH!t@@@ x@I@@@ y&StdlibJ%Uchar*utf_decode@@@ z@@ {@@ |@|22|22@@o@@1is_valid_utf_16be@&StringK!t@@@ }L@@@ ~@@ @3333<@@p@@2get_utf_16le_uchar@&StringM!t@@@ @N@@@ &StdlibO%Uchar*utf_decode@@@ @@ @@ @3333@@q@@1is_valid_utf_16le@&StringP!t@@@ Q@@@ @@ @.4F4F/4F4g@@-r@@-edit_distance%limit2R@@@ @@@ @&StringS!t@@@ @&StringT!t@@@ LU@@@ @@ @@ @@ @^44_45@@]s@@*spellcheck(max_dist0@vV@@@ hW@@@ @@ @@@ @@@X@@@ Y@@@ @@ Z@@@ @@ @[@@@ ]\@@@ @@@ @@ @@ @@ @8889 @@t@@)get_uint8@^@@@ @_@@@ `@@@ @@ @@ @?Y?Y?Y?}@@u@@(get_int8@a@@@ @b@@@ c@@@ @@ @@ @???@@@v@@-get_uint16_ne@d@@@ @e@@@ f@@@ @@ @@ @@{@{@{@@@w@@-get_uint16_be@g@@@ @h@@@ i@@@ @@ @@ @A%A%A%AM@@x@@-get_uint16_le@#j@@@ @k@@@ l@@@ @@ @@ @.AA/AA@@-y@@,get_int16_ne@?m@@@ @3n@@@ 8o@@@ @@ @@ @JBvBvKBvB@@Iz@@,get_int16_be@[p@@@ @Oq@@@ Tr@@@ @@ @@ @fCCgCCC@@e{@@,get_int16_le@ws@@@ @kt@@@ pu@@@ @@ @@ @CCCC@@|@@,get_int32_ne@v@@@ @w@@@ %int32x@@@ @@ @@ @ DeDe DeD@@}@@$hash@&Stringy!t@@@ z@@@ @@ @EEEE@@~@@+seeded_hash@{@@@ @&String|!t@@@ }@@@ @@ @@ @EEEF @@@@,get_int32_be@~@@@ @@@@ T@@@ @@ @@ @ FF FG@@@@@,get_int32_le@@@@ @@@@ p@@@ @@ @@ @'GG'GG@@ A@@,get_int64_ne@@@@ @@@@ %int64@@@ @@ @@ @+.H%H%,.H%HN@@*B@@,get_int64_be@<@@@ @0@@@ @@@ @@ @@ @G5HHH5HH@@FC@@,get_int64_le@X@@@ @L@@@ 9@@@ @@ @@ @c<IdIdd<IdI@@bD@@*unsafe_get@t@@@ @h@@@ e@@@ @@ @@ 2%string_unsafe_getBA@@@@GJQJQGJQJ@@E@@+unsafe_blit@@@@ @@@@ @@@@ @@@@ @@@@ @@@ @@ @@ @@ @@ @@ 0caml_blit_stringE@O@@@@@@@HJJJJJ@'noallocJJJJJJ@@JJJ @@F@@@3(Strings.@. A string !s+ of length !n / is an indexable and immutable sequence of !n M bytes. For historical reasons these bytes are referred to as characters.@ The semantics of string functions is defined in terms of indices and positions. These are depicted and described as follows.@! positions 0 1 2 3 4 n-1 n +---+---+---+---+ +-----+ indices | 0 | 1 | 2 | 3 | ... | n-1 | +---+---+---+---+ +-----+% #An %index@! !i$ of !s= is an integer in the range [!0!;#n-1<]. It represents the !i7th byte (character) of !s V which can be accessed using the constant time string indexing operator %s.[i]!.@"A (position@! !i$ of !s $ is an integer in the range [!0!;!n ]. It represents either the point at the beginning of the string, or the point between two indices, or the point at the end of the string. The !i )th byte index is between position !i% and #i+1!.@@@2 Two integers %start% and #len6 are said to define a 3valid substring@$ of !s$ if (len >= 0% and %start", )start+len6 are positions of !s!.@% -Unicode text.@  Strings being arbitrary sequences of bytes, they can hold any kind of textual encoding. However the recommended encoding for storing Unicode text in OCaml strings is UTF-8. This is the encoding used by Unicode escapes in string literals. For example the string +"\u{1F42B}" < is the UTF-8 encoding of the Unicode character U+1F42B.@% 0Past mutability.@ D Before OCaml 4.02, strings used to be modifiable in place like 'Bytes.t@@ mutable sequences of bytes. OCaml 4 had various compiler flags and configuration options to support the transition period from mutable to immutable strings. Those options are no longer available, and strings are now always immutable.@ L The labeled version of this module can be used as described in the )StdLabels@@( module.@@@@@@@@@@@@A7../../stdlib/string.mliA'strings'Strings@@#(String.t35The type for strings.@@@@@@@@@@@@@@A @  @@+String.make3(make n c7 is a string of length !n + with each index holding the character !c!.@@@@@@@@0Invalid_argument#if %n < 0$ or $n > 5Sys.max_string_length@@!.@@@@@ @  @ @@@@ +String.init3(init n f7 is a string of length !n0 with index !i7 holding the character #f i $ (called in increasing index order).@@@@$4.02@@@0Invalid_argument#if %n < 0$ or $n > 5Sys.max_string_length@@!.@@@@@ %@? &@B "@@@@ ,String.empty31The empty string.@@@@$4.13@@@@@@@ @@@@ -String.length3(length s / is the length (number of bytes/characters) of !s!.@@@@@@@@@@@@ @h @@@@ *String.get3'get s i; is the character at index !i$ in !s ". This is the same as writing %s.[i]!.@@@@@@@@0Invalid_argument#if !i1 not an index of !s!.@@@@@ 9@ :@ 6@@@@ )/String.of_bytes3 PReturn a new string that contains the same bytes as the given byte sequence.@@@@$4.13@@@@@@@ ,@ -@@@@ $/String.to_bytes3 PReturn a new byte sequence that contains the same bytes as the given string.@@@@$4.13@@@@@@@ '@ (@@@@ +String.blit3(Same as 1Bytes.blit_string@@; which should be preferred.@@@@@@@@@@@@ '@ (@ $@ @ @ @@@@ A&concat-Concatenating@@% %Note.@% The ,Stdlib.( ^ )@@ . binary operator concatenates two strings.@-String.concat3-concat sep ss " concatenates the list of strings "ss %, inserting the separator string #sep. between each.@@@@@@@@0Invalid_argument !if the result is longer than 5Sys.max_string_length@@' bytes.@@@@@ F@) G@, C@@@@ 4*String.cat3)cat s1 s29 concatenates s1 and s2 ('s1 ^ s2").@@@@$4.13@@@0Invalid_argument !if the result is longer than 5Sys.max_string_length@@' bytes.@@@@@ L@R M@U I@@@@ AA*predicates:Predicates and comparisons@@,String.equal3+equal s0 s1$ is $true0 if and only if "s0% and "s1> are character-wise equal.@@@@;4.03 (4.05 in StringLabels)@@@@@@@ b@ c@ \@@@@ P.String.compare3-compare s0 s1' sorts "s0% and "s1; in lexicographical order. 'compare2 behaves like .Stdlib.compare@@ & on strings but may be more efficient.@@@@@@@@@@@@ l@ m@ f@@@@ [2String.starts_with3,starts_with )~prefix s$ is $true0 if and only if !s1 starts with &prefix!.@@@@$4.13@@@@@@@ v@ v u@ q@@@@ i0String.ends_with3*ends_with )~suffix s$ is $true0 if and only if !s+ ends with &suffix!.@@@@$4.13@@@@@@@ @  @  @@@@ w4String.contains_from37contains_from s start c$ is $true0 if and only if !c, appears in !s4 after position %start!.@@@@@@@@0Invalid_argument#if %start< is not a valid position in !s!.@@@@@ @H @K @N @@@@ 5String.rcontains_from37rcontains_from s stop c$ is $true0 if and only if !c, appears in !s5 before position &stop+1!.@@@@@@@@0Invalid_argument#if (stop < 0$ or &stop+1 is not a valid position in !s!.@@@@@ @ @ @ @@@@ /String.contains3,contains s c$ is D@& s 0 c!.@@@@@@@@@@@@ @ @ @@@@ A'extract5Extracting substrings@@*String.sub3-sub s pos len7 is a string of length #len ", containing the substring of !s9 that starts at position #pos4 and has length #len!.@@@@@@@@0Invalid_argument#if #pos% and #len + do not designate a valid substring of !s!.@@@@@ @ @ @ @@@@ 렕4String.split_on_char33split_on_char sep s 7 is the list of all (possibly empty) substrings of !s % that are delimited by the character #sep). If !s , is empty, the result is the singleton list $[""]!.@ I The function's result is specified by the following invariants: 6The list is not empty.@ !Concatenating its elements using #sep ; as a separator returns a string equal to the input ( 3concat (make 1 sep) (split_on_char sep s) = s").@ %No string in the result contains the #sep+ character.@@@@@@;4.04 (4.05 in StringLabels)@@@@@@@ -@U .@X *@@@@ A,transforming,Transforming@@*String.map3'map f s ' is the string resulting from applying !f> to all the characters of !s5 in increasing order.@@@@$4.00@@@@@@@ 7@ 8@ -@@@@ %+String.mapi3(mapi f s) is like /D@ 6 but the index of the character is also passed to !f!.@@@@$4.02@@@@@@@ 7@ 8@ &@@@@ 0String.fold_left3/fold_left f x s* computes )f (... (f (f x s.[0]) s.[1]) ...) s.[n-1],, where !n= is the length of the string !s!.@@@@$4.13@@@@@@@ 6@ 7@ 8@ *@@@@ '1String.fold_right30fold_right f s x* computes *f s.[0] (f s.[1] ( ... (f s.[n-1] x) ...)),, where !n= is the length of the string !s!.@@@@$4.13@@@@@@@ ?@ @@ 2@ =@@@@ 0.String.for_all3+for_all p s= checks if all characters in !s7 satisfy the predicate !p!.@@@@$4.13@@@@@@@ B@ C@" 8@@@@ 0-String.exists3*exists p s % checks if at least one character of !s= satisfies the predicate !p!.@@@@$4.13@@@@@@@ B@B C@E 8@@@@ 0+String.trim3&trim s$ is !s I without leading and trailing whitespace. Whitespace characters are: #' '", &'\x0C'. (form feed), $'\n'", $'\r'&, and $'\t'!.@@@@$4.00@@@@@@@ Z@} [@@@@ S.String.escaped3)escaped s$ is !s i with special characters represented by escape sequences, following the lexical conventions of OCaml.@ All characters outside the US-ASCII printable range [0x20;0x7E] are escaped, as well as backslash (0x2F) and double-quote (0x22).@2 The function /Scanf.unescaped@@6 is a left inverse of 'escaped+, i.e. ?Scanf.unescaped (escaped s) = s0 for any string !s- (unless )escaped s( fails).@@@@@@@@0Invalid_argument !if the result is longer than 5Sys.max_string_length@@' bytes.@@@@@ @ @@@@ 6String.uppercase_ascii31uppercase_ascii s$ is !s Z with all lowercase letters translated to uppercase, using the US-ASCII character set.@@@@;4.03 (4.05 in StringLabels)@@@@@@@ @ @@@@ 6String.lowercase_ascii31lowercase_ascii s$ is !s Z with all uppercase letters translated to lowercase, using the US-ASCII character set.@@@@;4.03 (4.05 in StringLabels)@@@@@@@ @ @@@@ 7String.capitalize_ascii32capitalize_ascii s$ is !s Q with the first character set to uppercase, using the US-ASCII character set.@@@@;4.03 (4.05 in StringLabels)@@@@@@@ @ @@@@ 9String.uncapitalize_ascii34uncapitalize_ascii s$ is !s Q with the first character set to lowercase, using the US-ASCII character set.@@@@;4.03 (4.05 in StringLabels)@@@@@@@ @/ @@@@ A*traversing*Traversing@@+String.iter3(iter f s2 applies function !f " in turn to all the characters of !s:. It is equivalent to -f s.[0]; f s.[1]; ...; f s.[length s - 1]; ()!.@@@@@@@@@@@@ @\ @_ @@@@ ,String.iteri3%iteri) is like 3D@ G, but the function is also given the corresponding character index.@@@@$4.00@@@@@@@ @y @| @@@@ A)searching)Searching@@1String.index_from30index_from s i c ) is the index of the first occurrence of !c( in !s0 after position !i!.@@@@@@@@)Not_found#if !c3 does not occur in !s0 after position !i!.@0Invalid_argument#if !i< is not a valid position in !s!.@@@@@ @ @ @ @@@@ ֠5String.index_from_opt34index_from_opt s i c ) is the index of the first occurrence of !c( in !s0 after position !i* (if any).@@@@$4.05@@@0Invalid_argument#if !i< is not a valid position in !s!.@@@@@ @ @ @ @@@@ ꠕ2String.rindex_from31rindex_from s i c ( is the index of the last occurrence of !c( in !s1 before position #i+1!.@@@@@@@@)Not_found#if !c3 does not occur in !s1 before position #i+1!.@0Invalid_argument#if #i+1< is not a valid position in !s!.@@@@@ *@e +@h '@k #@@@@ 6String.rindex_from_opt35rindex_from_opt s i c ( is the index of the last occurrence of !c( in !s1 before position #i+1* (if any).@@@@$4.05@@@0Invalid_argument#if #i+1< is not a valid position in !s!.@@@@@ E@ F@ B@ >@@@@ 1,String.index3)index s c$ is 0D@& s 0 c!.@@@@@@@@@@@@ >@ ?@ ;@@@@ 30String.index_opt3-index_opt s c$ is D@& s 0 c!.@@@@$4.05@@@@@@@ B@ C@ ?@@@@ 2-String.rindex3*rindex s c$ is ܐD@3 s (length s - 1) c!.@@@@@@@@@@@@ ?@ @@ <@@@@ 41String.rindex_opt3.rindex_opt s c$ is D@3 s (length s - 1) c!.@@@@$4.05@@@@@@@ C@" D@% @@@@@ 3A@5Strings and Sequences@@-String.to_seq3(to_seq s G is a sequence made of the string's characters in increasing order.@@@@$4.07@@@@@@@ @@@ A@@@@ +.String.to_seqi3)to_seqi s) is like  D@ ) but also tuples the corresponding index.@@@@$4.07@@@@@@@ 7@Z 8@@@@ -String.of_seq3(of_seq s / is a string made of the sequence's characters.@@@@$4.07@@@@@@@ @n @@@@ A#utf List.iter yield l)!.@ V All strings are assumed to be UTF-8 encoded, decoding errors are replaced by )Uchar.rep@@, characters.@@@@#5.4@@@@@@@ @  @ W @ Z @@@@ ̠A@;Binary decoding of integers@@ BThe functions in this section binary decode integers from strings.@ # All following functions raise 0Invalid_argument ' if the characters needed at index !i ) to decode the integer are not available.@ Little-endian (resp. big-endian) encoding means that least (resp. most) significant bytes are stored first. Big-endian is also known as network byte order. Native-endian encoding is either little-endian or big-endian depending on .Sys.big_endian@@!.@ 7 32-bit and 64-bit integers are represented by the %int32) and %int64 J types, which can be interpreted either as signed or unsigned numbers.@ 6 8-bit and 16-bit integers are represented by the #int type, which has more bits than the binary encoding. These extra bits are sign-extended (or zero-extended) for functions which decode 8-bit or 16-bit integers and represented them with #int( values.@0String.get_uint83-get_uint8 b i$ is !b :'s unsigned 8-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ $@  %@  !@@@@ /String.get_int83,get_int8 b i$ is !b 8's signed 8-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ +@  ,@  (@@@@ 4String.get_uint16_ne31get_uint16_ne b i$ is !b I's native-endian unsigned 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ 2@  3@  /@@@@ '4String.get_uint16_be31get_uint16_be b i$ is !b F's big-endian unsigned 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ 9@ ) :@ , 6@@@@ .4String.get_uint16_le31get_uint16_le b i$ is !b I's little-endian unsigned 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ @@ L A@ O =@@@@ 53String.get_int16_ne30get_int16_ne b i$ is !b G's native-endian signed 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ G@ o H@ r D@@@@ <3String.get_int16_be30get_int16_be b i$ is !b D's big-endian signed 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ N@  O@  K@@@@ C3String.get_int16_le30get_int16_le b i$ is !b G's little-endian signed 16-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ U@  V@  R@@@@ J3String.get_int32_ne30get_int32_ne b i$ is !b @'s native-endian 32-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ \@  ]@  Y@@@@ P+String.hash3 IAn unseeded hash function for strings, with the same output value as ,Hashtbl.hash@@ O. This function allows this module to be passed as argument to the functor ,Hashtbl.Make@@!.@@@@#5.0@@@@@@@ _@  `@@@@ U2String.seeded_hash3 FA seeded hash function for strings, with the same output value as 3Hashtbl.seeded_hash@@ O. This function allows this module to be passed as argument to the functor 2Hashtbl.MakeSeeded@@!.@@@@#5.0@@@@@@@ d@  e@  a@@@@ V3String.get_int32_be30get_int32_be b i$ is !b ='s big-endian 32-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ h@ 8 i@ ; e@@@@ ]3String.get_int32_le30get_int32_le b i$ is !b @'s little-endian 32-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ o@ [ p@ ^ l@@@@ d3String.get_int64_ne30get_int64_ne b i$ is !b @'s native-endian 64-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ v@ ~ w@  s@@@@ j3String.get_int64_be30get_int64_be b i$ is !b ='s big-endian 64-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ |@  }@  y@@@@ q3String.get_int64_le30get_int64_le b i$ is !b @'s little-endian 64-bit integer starting at character index !i!.@@@@$4.13@@@@@@@ @  @  @@@@ x@@ @@A%Uchar#Seq@@@@@