code: func (er *edgeIndex) enforceLinked(id string, k *CacheKey) {
  	main, ok := er.items[id]
  	if !ok {
  		main = &indexItem{
  			links: map[CacheInfoLink]map[string]struct{}{},
  			deps:  map[string]struct{}{},
  		}
  		er.items[id] = main
  	}
  
  	deps := k.Deps()
  
  	for i, dd := range deps {
  		for _, d := range dd {
  			ck := d.CacheKey.CacheKey
  			er.enforceIndexID(ck)
  			ll := CacheInfoLink{Input: Index(i), Digest: k.Digest(), Output: k.Output(), Selector: d.Selector}
  			for _, ckID := range ck.indexIDs {
  				if item, ok := er.items[ckID]; ok {
  					links, ok := item.links[ll]
  					if !ok {
  						links = map[string]struct{}{}
  						item.links[ll] = links
  					}
  					links[id] = struct{}{}
  					main.deps[ckID] = struct{}{}
  				}
  			}
  		}
  	}
  }
docs: // enforceLinked adds links from current ID to all dep keys