I need to convert this Erlang code to Elixir.
fun(OtpTemp, otp) when OtpTemp#otp.genenrated_time < time ->
[OtpTemp | otp];
(_, otp) ->
IO.inspect(otp)
end,
I need to convert this Erlang code to Elixir.
fun(OtpTemp, otp) when OtpTemp#otp.genenrated_time < time ->
[OtpTemp | otp];
(_, otp) ->
IO.inspect(otp)
end,
Copyright © 2021 Jogjafile Inc.
This is not a valid erlang code in the first place. Erlang has no clue about
IO.inspect/1and(_, otp)would raise as well.Record might (or might not) be a map in elixir, funs are funs.