code: func appendIfMissing(slice []cty.Value, element cty.Value) ([]cty.Value, error) {
  	for _, ele := range slice {
  		eq, err := stdlib.Equal(ele, element)
  		if err != nil {
  			return slice, err
  		}
  		if eq.True() {
  			return slice, nil
  		}
  	}
  	return append(slice, element), nil
  }
docs: // helper function to add an element to a list, if it does not already exist