Hello!
I want to “save function” (module, name, arity) to the database to be able to call it later, potentially after BEAM was restarted. My plan is to use Functions.capture(module, function_name, arity)
to be able to call the function after “loading” from the database.
How can I obtain module, function name and arity from a function capture (e.g. &MyModule.my_function/0
) to “save function”? I have found Functions.info(fun)
function, however, the documentation has a note saying that it should be used for debug only. What are the reasons it is debug only? What are the alternatives?