Enclose tmpbuf in a module instead of a let block

This avoids boxing on calling show for integers