added anonymous functions support