FunFunc v0.1.0 FunFunc
This library provides helper functions.
Sample
use FunFunc
Agent.start_link(return(1), name: __MODULE__)
Agent.cast(__MODULE__, const(2))
Agent.get(__MODULE__, id())
use
When use FunFunc
, it means:
import FunFunc
alias FunFunc.{Func, Nilable, Num, Result, Tuple, Value}
Link to this section Summary
Link to this section Functions
Link to this function
const(x)
See FunFunc.Func.const/1
.
Example
iex> FunFunc.const(1).(2)
1
See FunFunc.Func.id/0
.
Example
iex> FunFunc.id().(1)
1
Link to this function
ignore(x)
Example
iex> FunFunc.ignore(1).(2)
2
Link to this function
return(x)
Example
iex> FunFunc.return(1).()
1