fn.define receives function