added lambda and proc support