From 453de8d740803612c21e01ddff41ea75b60c251c Mon Sep 17 00:00:00 2001 From: Frank Hunleth Date: Sun, 16 Jun 2024 08:24:31 -0400 Subject: [PATCH] Update Erlang strings to use ~c sigil MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This fixes the following warnings in Elixir 1.17: ``` ==> gen_state_machine Compiling 3 files (.ex) warning: single-quoted strings represent charlists. Use ~c"" if you indeed want a charlist or use "" instead │ 21 │ {'** State machine ~tp terminating~n' ++ _ = format, args} -> │ ~ │ └─ lib/gen_state_machine/translator.ex:21:8 warning: single-quoted strings represent charlists. Use ~c"" if you indeed want a charlist or use "" instead │ 24 │ {'** State machine ~p terminating~n' ++ _ = format, args} -> │ ~ │ └─ lib/gen_state_machine/translator.ex:24:8 ``` --- lib/gen_state_machine/translator.ex | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/gen_state_machine/translator.ex b/lib/gen_state_machine/translator.ex index e5d5f13..64c3ef6 100644 --- a/lib/gen_state_machine/translator.ex +++ b/lib/gen_state_machine/translator.ex @@ -18,10 +18,10 @@ defmodule GenStateMachine.Translator do opts = Application.get_env(:logger, :translator_inspect_opts) case message do - {'** State machine ~tp terminating~n' ++ _ = format, args} -> + {~c"** State machine ~tp terminating~n" ++ _ = format, args} -> do_translate(min_level, format, args, opts) - {'** State machine ~p terminating~n' ++ _ = format, args} -> + {~c"** State machine ~p terminating~n" ++ _ = format, args} -> do_translate(min_level, format, args, opts) _ ->