code: func (v ElementBuildingVisitor) createMapValues(
  	schemaFn schemaFn,
  	meta apply.FieldMetaImpl,
  	data apply.MapElementData) (map[string]apply.Element, error) {
  
  	// Collate each key in the map
  	values := map[string]apply.Element{}
  	for _, key := range keysUnion(data.GetRecordedMap(), data.GetLocalMap(), data.GetRemoteMap()) {
  		combined := apply.RawElementData{}
  		if recorded, recordedSet := nilSafeLookup(key, data.GetRecordedMap()); recordedSet {
  			combined.SetRecorded(recorded)
  		}
  		if local, localSet := nilSafeLookup(key, data.GetLocalMap()); localSet {
  			combined.SetLocal(local)
  		}
  		if remote, remoteSet := nilSafeLookup(key, data.GetRemoteMap()); remoteSet {
  			combined.SetRemote(remote)
  		}
  
  		// Create an item for the field
  		field, err := v.getItem(schemaFn(key), key, combined)
  		if err != nil {
  			return nil, err
  		}
  
  		// Build the element for this field
  		element, err := field.CreateElement(v)
  		if err != nil {
  			return nil, err
  		}
  
  		// Add the field element to the map
  		values[key] = element
  	}
  	return values, nil
  }
docs: // createMapValues combines the recorded, local and remote values from
  // data into a map of elements.