Skip to content

Commit 89e8d88

Browse files
Update lib/elixir/lib/exception.ex
Co-authored-by: José Valim <[email protected]>
1 parent 07afa2c commit 89e8d88

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

lib/elixir/lib/exception.ex

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1997,8 +1997,9 @@ defmodule Protocol.UndefinedError do
19971997

19981998
@impl true
19991999
def message(%{protocol: protocol, value: value, description: description}) do
2000-
"protocol #{inspect(protocol)} not implemented for #{inspect(value, pretty: true)} of type " <>
2001-
value_type(value) <> maybe_description(description) <> maybe_available(protocol)
2000+
"protocol #{inspect(protocol)} not implemented type " <> value_type(value) <>
2001+
maybe_description(description) <> maybe_available(protocol) <>
2002+
"\n\nGot value: #{inspect(value, pretty: true)}"
20022003
end
20032004

20042005
defp value_type(%{__struct__: struct}), do: "#{inspect(struct)} (a struct)"

0 commit comments

Comments
 (0)