Dialyxir.Warnings.GuardFail (Dialyxir v1.4.3) View Source

The function guard either presents an impossible guard or the only calls will never succeed against the guards.

Example

defmodule Example do
  def ok() do
    ok(0)
  end

  defp ok(n) when n > 1 do
    :ok
  end
end

or

defmodule Example do
  def ok() when 0 > 1 do
    :ok
  end
end