support for arbitrary partial application and currying added
restructure