#27 Change deftype support to create methods instead of functions