Closed as not planned
Description
Elixir and Erlang/OTP versions
Elixir 1.18.0-dev (4328b09) (compiled with Erlang/OTP 27)
Operating system
Linux
Current behavior
With the following code snippet:
defmodule Foo do
def something(input) do
case module(input) do
:error -> ""
module -> module.zar()
end
end
def zar() do
end
defp module(input) do
if input == "bar" do
:error
else
Foo
end
end
end
I get the following warning:
warning: :error.zar/0 is undefined (module :error is not available or is yet to be defined)
│
5 │ module -> module.zar()
│ ~
│
└─ foo.exs:5:24: Foo.something/1
Expected behavior
The handles the :error case, so the warning is a false positive.
Metadata
Metadata
Assignees
Labels
No labels