ast: Fix writing of -TAB headers

With this fix, and recent other changes, it is now possible to export
HARP NDFs as "-TAB" FITS files using ndf2fits.