code: func (enc *Encoder) WriteType(sig *Signature) error {
  	if enc.tagged {
  		enc.tagged = false
  		return nil
  	}
  	return enc.compileSignature(sig, &enc.buf) //as a side-effect, this defines new tags
  }
docs: // WriteType takes a signature and writes the tag for it. If it is the first time
  // the signature has been encountered, a new tag is allocated and written followed
  // by its definition.