hamts, function properties, 'protect' monad, wrapper functions, macro bugfix