Improve haddock
Remove tpe function (seems useless to me)
Minor readability tweaks