fix(logging): text log formatter avoid binary literals

This commit is contained in:
Zaiming Shi 2021-08-02 23:06:37 +02:00
parent 58d0717b2f
commit 3cda69fa3f
1 changed files with 1 additions and 4 deletions

View File

@ -36,7 +36,4 @@ enrich_fmt(Fmt, Args, #{mfa := Mfa, line := Line}) ->
enrich_fmt(Fmt, Args, _) ->
{Fmt, Args}.
mfa({M, F, A}) ->
<<(atom_to_binary(M, utf8))/binary, $:,
(atom_to_binary(F, utf8))/binary, $/,
(integer_to_binary(A))/binary>>.
mfa({M, F, A}) -> atom_to_list(M) ++ ":" ++ atom_to_list(F) ++ "/" ++ integer_to_list(A).