code: func (pm *PermanodeMeta) appendAttrClaim(cl *camtypes.Claim, signers signerFromBlobrefMap) error {
  	signer, ok := signers[cl.Signer]
  	if !ok {
  		return fmt.Errorf("claim %v has unknown signer %q", cl.BlobRef, cl.Signer)
  	}
  	sc, ok := pm.signer[signer]
  	if !ok {
  		// Optimize for the case where cl.Signer of all claims are the same.
  		// Instead of having two identical attrValues copies in
  		// pm.attr and pm.signer[cl.Signer],
  		// use a single attrValues
  		// until there is at least a second signer.
  		switch len(pm.signer) {
  		case 0:
  			// Set up signer cache to reference
  			// the existing attrValues.
  			pm.attr.cacheAttrClaim(cl)
  			pm.signer[signer] = pm.attr
  			return nil
  
  		case 1:
  			// pm.signer has exactly one other signer,
  			// and its attrValues entry references pm.attr.
  			// Make a copy of pm.attr
  			// for this other signer now.
  			m := make(attrValues)
  			for a, v := range pm.attr {
  				xv := make([]string, len(v))
  				copy(xv, v)
  				m[a] = xv
  			}
  
  			for sig := range pm.signer {
  				pm.signer[sig] = m
  				break
  			}
  		}
  		sc = make(attrValues)
  		pm.signer[signer] = sc
  	}
  
  	pm.attr.cacheAttrClaim(cl)
  
  	// Cache claim in sc only if sc != pm.attr.
  	if len(pm.signer) > 1 {
  		sc.cacheAttrClaim(cl)
  	}
  	return nil
  }
docs: // appendAttrClaim stores permanode attributes
  // from cl in pm.attr and pm.signer[signerID[cl.Signer]].
  // The caller of appendAttrClaim is responsible for calling
  // it with claims sorted in camtypes.ClaimPtrsByDate order.