implement TermsWriter.finish()