diff options
Diffstat (limited to 'src/gleam_stdlib.erl')
-rw-r--r-- | src/gleam_stdlib.erl | 28 |
1 files changed, 16 insertions, 12 deletions
diff --git a/src/gleam_stdlib.erl b/src/gleam_stdlib.erl index 562ef23..ffea232 100644 --- a/src/gleam_stdlib.erl +++ b/src/gleam_stdlib.erl @@ -3,18 +3,19 @@ -export([ map_get/2, iodata_append/2, identity/1, decode_int/1, decode_bool/1, decode_float/1, decode_list/1, decode_option/2, decode_field/2, parse_int/1, - parse_float/1, less_than/2, string_pop_grapheme/1, string_starts_with/2, - wrap_list/1, string_ends_with/2, string_pad/4, decode_map/1, uri_parse/1, - bit_array_int_to_u32/1, bit_array_int_from_u32/1, decode_result/1, - bit_array_slice/3, decode_bit_array/1, compile_regex/2, regex_scan/2, - percent_encode/1, percent_decode/1, regex_check/2, regex_split/2, - base_decode64/1, parse_query/1, bit_array_concat/1, - bit_array_base64_encode/2, size_of_tuple/1, - decode_tuple/1, decode_tuple2/1, decode_tuple3/1, decode_tuple4/1, - decode_tuple5/1, decode_tuple6/1, tuple_get/2, classify_dynamic/1, print/1, - println/1, print_error/1, println_error/1, inspect/1, float_to_string/1, - int_from_base_string/2, utf_codepoint_list_to_string/1, contains_string/2, - crop_string/2, base16_decode/1, string_replace/3, regex_replace/3, slice/3, bit_array_to_int_and_size/1 + parse_float/1, less_than/2, string_pop_grapheme/1, string_pop_codeunit/1, + string_starts_with/2, wrap_list/1, string_ends_with/2, string_pad/4, + decode_map/1, uri_parse/1, bit_array_int_to_u32/1, bit_array_int_from_u32/1, + decode_result/1, bit_array_slice/3, decode_bit_array/1, compile_regex/2, + regex_scan/2, percent_encode/1, percent_decode/1, regex_check/2, + regex_split/2, base_decode64/1, parse_query/1, bit_array_concat/1, + bit_array_base64_encode/2, size_of_tuple/1, decode_tuple/1, decode_tuple2/1, + decode_tuple3/1, decode_tuple4/1, decode_tuple5/1, decode_tuple6/1, + tuple_get/2, classify_dynamic/1, print/1, println/1, print_error/1, + println_error/1, inspect/1, float_to_string/1, int_from_base_string/2, + utf_codepoint_list_to_string/1, contains_string/2, crop_string/2, + base16_decode/1, string_replace/3, regex_replace/3, slice/3, + bit_array_to_int_and_size/1 ]). %% Taken from OTP's uri_string module @@ -203,6 +204,9 @@ string_pop_grapheme(String) -> _ -> {error, nil} end. +string_pop_codeunit(<<Cp/integer, Rest/binary>>) -> {Cp, Rest}; +string_pop_codeunit(Binary) -> {0, Binary}. + bit_array_concat(BitArrays) -> list_to_bitstring(BitArrays). |