Move reusable stuff to funs.xsl