Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.
 
 
 
 

27 строки
618 B

-compile(export_all).
msg(Fmt, Args) ->
M1 = io_lib:format(Fmt, Args),
M2 = re:replace(M1, <<"\r">>, <<"\\\\r">>, [global]),
M3 = re:replace(M2, <<"\n">>, <<"\\\\n">>, [global]),
M4 = re:replace(M3, <<"\t">>, <<"\\\\t">>, [global]),
iolist_to_binary(M4).
hex(Bin) when is_binary(Bin) ->
H1 = [io_lib:format("16#~2.16.0B",[X]) || <<X:8>> <= Bin],
H2 = string:join(H1, ", "),
lists:flatten(io_lib:format("<<~s>>", [lists:flatten(H2)])).
dec(V) ->
jiffy:decode(V).
enc(V) ->
iolist_to_binary(jiffy:encode(V)).
enc(V, Opts) ->
iolist_to_binary(jiffy:encode(V, Opts)).