unify.clj for export to scala