code: func WithName(name string) (Named, error) {
  	if len(name) > NameTotalLengthMax {
  		return nil, ErrNameTooLong
  	}
  
  	match := anchoredNameRegexp.FindStringSubmatch(name)
  	if match == nil || len(match) != 3 {
  		return nil, ErrReferenceInvalidFormat
  	}
  	return repository{
  		domain: match[1],
  		path:   match[2],
  	}, nil
  }
docs: // WithName returns a named object representing the given string. If the input
  // is invalid ErrReferenceInvalidFormat will be returned.